Foxit PDF SDK

Public Member Functions | Static Public Attributes | List of all members
com.foxit.sdk.addon.conversion.HTML2PDFSettingData Class Reference

## Public Member Functions
| HTML2PDFSettingData ()
| Constructor.
| HTML2PDFSettingData (float page_width, float page_height, boolean is_to_page_scale, RectF page_margin, boolean is_convert_link, int rotate_degrees, boolean is_generate_tag, int page_mode, boolean to_generate_bookmarks, int scaling_mode, int encoding_format, boolean to_render_images, boolean to_remove_underline_for_link, boolean to_set_headerfooter, String headerfooter_title, String headerfooter_url, String bookmark_root_name, boolean to_resize_objects, boolean to_print_background, boolean to_optimize_tag_tree, int media_style, boolean to_load_active_content, boolean to_disable_sandbox, boolean to_use_blacklist, boolean to_hide_header, boolean to_hide_footer, boolean to_deny_local_file_access)
| Constructor, with parameters. More...
synchronized void | delete ()
| Clean up related C++ resources immediately. More...
String | getBookmark_root_name ()
| Get the bookmark's root name. More...
int | getEncoding_format ()
| Get the HTML encoding format Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_EncodingFormatDefault and this should be one of these values. More...
String | getHeaderfooter_title ()
| Get the header-footer title which is content for center header. More...
String | getHeaderfooter_url ()
| Get the header-footer url which is content for left footer. More...
boolean | getIs_convert_link ()
| Get used to decide whether the web link should be converted or not. More...
boolean | getIs_generate_tag ()
| Get used to decide whether the tag should be generated or not. More...
boolean | getIs_to_page_scale ()
| Get used to decide whether to scale the converted PDF page or not. More...
int | getMedia_style ()
| Get the media style used for the converted PDF document. More...
float | getPage_height ()
| Get the page height used for the converted PDF document (unit is 1/72 inch). More...
RectF | getPage_margin ()
| Get the page margin used for converted PDF document. More...
int | getPage_mode ()
| Get the page mode used for the converting. More...
float | getPage_width ()
| Get the page width used for the converted PDF document (unit is 1/72 inch). More...
int | getRotate_degrees ()
| Get the rotation degree used for the converted PDF page. More...
int | getScaling_mode ()
| Get the scaling mode used for the converted PDF document. More...
boolean | getTo_deny_local_file_access ()
| Get used to decide whether to deny local file access or not during converting html file. More...
boolean | getTo_disable_sandbox ()
| Get used to decide whether to disable sandbox or not. More...
boolean | getTo_generate_bookmarks ()
| Get used to decide whether bookmarks should be generated or not. More...
boolean | getTo_hide_footer ()
| Get used to decide whether to hide footer or not. More...
boolean | getTo_hide_header ()
| Get used to decide whether to hide header or not. More...
boolean | getTo_load_active_content ()
| Get used to decide whether to load active content or not. More...
boolean | getTo_optimize_tag_tree ()
| Get used to decide whether to optimize tag tree or not. More...
boolean | getTo_print_background ()
| Get used to decide whether to print background or not. More...
boolean | getTo_remove_underline_for_link ()
| Get used to decide whether to remove underline decoration for link. More...
boolean | getTo_render_images ()
| Get used to decide whether to render images or not. More...
boolean | getTo_resize_objects ()
| Get whether to enable the Javascripts related resizing of the objects during rendering process. More...
boolean | getTo_set_headerfooter ()
| Get used to decide whether to set header-footer or not. More...
boolean | getTo_use_blacklist ()
| Get used to decide whether to use blacklist or not. More...
void | set (float page_width, float page_height, boolean is_to_page_scale, RectF page_margin, boolean is_convert_link, int rotate_degrees, boolean is_generate_tag, int page_mode, boolean to_generate_bookmarks, int scaling_mode, int encoding_format, boolean to_render_images, boolean to_remove_underline_for_link, boolean to_set_headerfooter, String headerfooter_title, String headerfooter_url, String bookmark_root_name, boolean to_resize_objects, boolean to_print_background, boolean to_optimize_tag_tree, int media_style, boolean to_load_active_content, boolean to_disable_sandbox, boolean to_use_blacklist, boolean to_hide_header, boolean to_hide_footer, boolean to_deny_local_file_access)
| Set value. More...
void | setBookmark_root_name (String value)
| Set the bookmark's root name. More...
void | setEncoding_format (int value)
| Set the HTML encoding format Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_EncodingFormatDefault and this should be one of these values. More...
void | setHeaderfooter_title (String value)
| Set the header-footer title which is content for center header. More...
void | setHeaderfooter_url (String value)
| Set the header-footer url which is content for left footer. More...
void | setIs_convert_link (boolean value)
| Set used to decide whether the web link should be converted or not. More...
void | setIs_generate_tag (boolean value)
| Set used to decide whether the tag should be generated or not. More...
void | setIs_to_page_scale (boolean value)
| Set used to decide whether to scale the converted PDF page or not. More...
void | setMedia_style (int value)
| Set the media style used for the converted PDF document. More...
void | setPage_height (float value)
| Set the page height used for the converted PDF document (unit is 1/72 inch). More...
void | setPage_margin (RectF value)
| Set the page margin used for converted PDF document. More...
void | setPage_mode (int value)
| Set the page mode used for the converting. More...
void | setPage_width (float value)
| Set the page width used for the converted PDF document (unit is 1/72 inch). More...
void | setRotate_degrees (int value)
| Set the rotation degree used for the converted PDF page. More...
void | setScaling_mode (int value)
| Set the scaling mode used for the converted PDF document. More...
void | setTo_deny_local_file_access (boolean value)
| Set used to decide whether to deny local file access or not during converting html file. More...
void | setTo_disable_sandbox (boolean value)
| Set used to decide whether to disable sandbox or not. More...
void | setTo_generate_bookmarks (boolean value)
| Set used to decide whether bookmarks should be generated or not. More...
void | setTo_hide_footer (boolean value)
| Set used to decide whether to hide footer or not. More...
void | setTo_hide_header (boolean value)
| Set used to decide whether to hide header or not. More...
void | setTo_load_active_content (boolean value)
| Set used to decide whether to load active content or not. More...
void | setTo_optimize_tag_tree (boolean value)
| Set used to decide whether to optimize tag tree or not. More...
void | setTo_print_background (boolean value)
| Set used to decide whether to print background or not. More...
void | setTo_remove_underline_for_link (boolean value)
| Set used to decide whether to remove underline decoration for link. More...
void | setTo_render_images (boolean value)
| Set used to decide whether to render images or not. More...
void | setTo_resize_objects (boolean value)
| Set whether to enable the Javascripts related resizing of the objects during rendering process. More...
void | setTo_set_headerfooter (boolean value)
| Set used to decide whether to set header-footer or not. More...
void | setTo_use_blacklist (boolean value)
| Set used to decide whether to use blacklist or not. More...

## Static Public Attributes
static final int | e_EncodingFormatArabic = 8
| Encoding foramt: "Arabic".
static final int | e_EncodingFormatASCII = 1
| Encoding foramt: "ASCII".
static final int | e_EncodingFormatASCII_7_bit = 22
| Encoding foramt: "ASCII-7-bit".
static final int | e_EncodingFormatBHASKAR = 54
| Encoding foramt: "BHASKAR".
static final int | e_EncodingFormatBIG5 = 14
| Encoding foramt: "BIG5".
static final int | e_EncodingFormatBIG5_CP950 = 21
| Encoding foramt: "BIG5-CP950".
static final int | e_EncodingFormatBIG5_HKSCS = 46
| Encoding foramt: "BIG5_HKSCS".
static final int | e_EncodingFormatCNS = 20
| Encoding foramt: "CNS".
static final int | e_EncodingFormatCP1250 = 28
| Encoding foramt: "CP1250".
static final int | e_EncodingFormatCP1251 = 29
| Encoding foramt: "CP1251".
static final int | e_EncodingFormatCP1252 = 30
| Encoding foramt: "CP1252".
static final int | e_EncodingFormatCP1253 = 31
| Encoding foramt: "CP1253".
static final int | e_EncodingFormatCP1254 = 32
| Encoding foramt: "CP1254".
static final int | e_EncodingFormatCP1255 = 33
| Encoding foramt: "CP1255".
static final int | e_EncodingFormatCP1256 = 34
| Encoding foramt: "CP1256".
static final int | e_EncodingFormatCP1257 = 35
| Encoding foramt: "CP1257".
static final int | e_EncodingFormatCP852 = 24
| Encoding foramt: "CP852".
static final int | e_EncodingFormatCP866 = 25
| Encoding foramt: "CP866".
static final int | e_EncodingFormatCP874 = 26
| Encoding foramt: "CP874".
static final int | e_EncodingFormatCP932 = 27
| Encoding foramt: "CP932".
static final int | e_EncodingFormatCSN_369103 = 41
| Encoding foramt: "CSN_369103".
static final int | e_EncodingFormatDefault = 0
| Encoding foramt: Default.The encoding format will be automatically detected in chromium.
static final int | e_EncodingFormatEUC = 19
| Encoding foramt: "EUC".
static final int | e_EncodingFormatEUC_CN = 16
| Encoding foramt: "EUC-CN".
static final int | e_EncodingFormatEUC_JP = 11
| Encoding foramt: "EUC-JP".
static final int | e_EncodingFormatGB = 15
| Encoding foramt: "GB".
static final int | e_EncodingFormatGB18030 = 45
| Encoding foramt: "GB18030".
static final int | e_EncodingFormatGBK = 44
| Encoding foramt: "GBK".
static final int | e_EncodingFormatGreek = 9
| Encoding foramt: "Greek".
static final int | e_EncodingFormatHebrew = 10
| Encoding foramt: "Hebrew".
static final int | e_EncodingFormatHTCHANAKYA = 55
| Encoding foramt: "HTCHANAKYA".
static final int | e_EncodingFormatHZ_GB_2312 = 61
| Encoding foramt: "HZ-GB-2312".
static final int | e_EncodingFormatISO_2022_CN = 47
| Encoding foramt: "ISO_2022_CN".
static final int | e_EncodingFormatISO_2022_KR = 43
| Encoding foramt: "ISO-2022-KR".
static final int | e_EncodingFormatISO_8859_11 = 38
| Encoding foramt: "ISO-8859-11".
static final int | e_EncodingFormatISO_8859_13 = 42
| Encoding foramt: "ISO-8859-13".
static final int | e_EncodingFormatISO_8859_15 = 37
| Encoding foramt: "ISO-8859-15".
static final int | e_EncodingFormatISO_8859_5 = 7
| Encoding foramt: "ISO-8859-5".
static final int | e_EncodingFormatISO_8859_8_I = 39
| Encoding foramt: "ISO-8859-8-I".
static final int | e_EncodingFormatJAGRAN = 51
| Encoding foramt: "JAGRAN".
static final int | e_EncodingFormatJIS = 13
| Encoding foramt: "JIS".
static final int | e_EncodingFormatKOI8R = 23
| Encoding foramt: "KOI8R".
static final int | e_EncodingFormatKOI8U = 36
| Encoding foramt: "KOI8U".
static final int | e_EncodingFormatKSC = 17
| Encoding foramt: "KSC".
static final int | e_EncodingFormatLatin2 = 2
| Encoding foramt: "Latin2".
static final int | e_EncodingFormatLatin3 = 3
| Encoding foramt: "Latin3".
static final int | e_EncodingFormatLatin4 = 4
| Encoding foramt: "Latin4".
static final int | e_EncodingFormatLatin5 = 5
| Encoding foramt: "Latin5".
static final int | e_EncodingFormatLatin6 = 6
| Encoding foramt: "Latin6".
static final int | e_EncodingFormatMACINTOSH = 52
| Encoding foramt: "MACINTOSH".
static final int | e_EncodingFormatSJS = 12
| Encoding foramt: "SJS".
static final int | e_EncodingFormatTAB = 50
| Encoding foramt: "TAB".
static final int | e_EncodingFormatTAM = 49
| Encoding foramt: "TAM".
static final int | e_EncodingFormatTSCII = 48
| Encoding foramt: "TSCII".
static final int | e_EncodingFormatUnicode = 18
| Encoding foramt: "Unicode".
static final int | e_EncodingFormatUTF7 = 53
| Encoding foramt: "UTF7".
static final int | e_EncodingFormatUTF_16BE = 56
| Encoding foramt: "UTF-16BE".
static final int | e_EncodingFormatUTF_16LE = 57
| Encoding foramt: "UTF-16LE".
static final int | e_EncodingFormatUTF_32BE = 58
| Encoding foramt: "UTF-32BE".
static final int | e_EncodingFormatUTF_32LE = 59
| Encoding foramt: "UTF-32LE".
static final int | e_EncodingFormatVISUAL = 40
| Encoding foramt: "VISUAL".
static final int | e_EncodingFormatX_BINARYENC = 60
| Encoding foramt: "X-BINARYENC".
static final int | e_EncodingFormatX_DoCoMo_Shift_JIS = 70
| Encoding foramt: "X-DoCoMo-Shift_JIS".
static final int | e_EncodingFormatX_KDDI_ISO_2022_JP = 72
| Encoding foramt: "X-KDDI-ISO-2022-JP".
static final int | e_EncodingFormatX_KDDI_Shift_JIS = 69
| Encoding foramt: "X-KDDI-Shift_JIS".
static final int | e_EncodingFormatX_SoftBank_ISO_2022_JP = 73
| Encoding foramt: "X-SoftBank-ISO-2022-JP".
static final int | e_EncodingFormatX_SoftBank_Shift_JIS = 71
| Encoding foramt: "X-SoftBank-Shift_JIS".
static final int | e_EncodingFormatX_TAM_ELANGO = 63
| Encoding foramt: "X-TAM-ELANGO".
static final int | e_EncodingFormatX_TAM_LTTMBARANI = 64
| Encoding foramt: "X-TAM-LTTMBARANI".
static final int | e_EncodingFormatX_TAM_SHREE = 65
| Encoding foramt: "X-TAM-SHREE".
static final int | e_EncodingFormatX_TAM_TBOOMIS = 66
| Encoding foramt: "X-TAM-TBOOMIS".
static final int | e_EncodingFormatX_TAM_TMNEWS = 67
| Encoding foramt: "X-TAM-TMNEWS".
static final int | e_EncodingFormatX_TAM_WEBTAMIL = 68
| Encoding foramt: "X-TAM-WEBTAMIL".
static final int | e_EncodingFormatX_UTF8UTF8 = 62
| Encoding foramt: "X-UTF8UTF8".
static final int | e_MediaStylePrint = 1
| Media style: print. It means PDF page will be displayed in print media style.
static final int | e_MediaStyleScreen = 0
| Media style: screen. It means PDF page will be displayed in screen media style.
static final int | e_PageModeMultiplePage = 1
| Multiple page mode.
static final int | e_PageModeSinglePage = 0
| Single page mode.
static final int | e_ScalingModeEnlarge = 2
| Page scaling: Enlarge. It means PDF page will be enlarged to HTML content size. In this mode, the text size of HTML content will not be changed.
static final int | e_ScalingModeNone = 0
| Scaling mode: Fixed page with no scale. In this mode, the text size of HTML content will not be changed.
static final int | e_ScalingModeScale = 1
| Page scaling: Scale. It means HTML content will be scaled to fit PDF page size. In this mode, the text size may be changed.

## Detailed Description

This class represents setting data used for converting HTML to PDF.

## Constructor & Destructor Documentation

## ◆ HTML2PDFSettingData()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.HTML2PDFSettingData | ( | float | page_width,
|  | float | page_height,
|  | boolean | is_to_page_scale,
|  | RectF | page_margin,
|  | boolean | is_convert_link,
|  | int | rotate_degrees,
|  | boolean | is_generate_tag,
|  | int | page_mode,
|  | boolean | to_generate_bookmarks,
|  | int | scaling_mode,
|  | int | encoding_format,
|  | boolean | to_render_images,
|  | boolean | to_remove_underline_for_link,
|  | boolean | to_set_headerfooter,
|  | String | headerfooter_title,
|  | String | headerfooter_url,
|  | String | bookmark_root_name,
|  | boolean | to_resize_objects,
|  | boolean | to_print_background,
|  | boolean | to_optimize_tag_tree,
|  | int | media_style,
|  | boolean | to_load_active_content,
|  | boolean | to_disable_sandbox,
|  | boolean | to_use_blacklist,
|  | boolean | to_hide_header,
|  | boolean | to_hide_footer,
|  | boolean | to_deny_local_file_access
| ) |  |

Constructor, with parameters.

Parameters

  [in] | page_width | The page width used for the converted PDF document (unit is 1/72 inch).
  [in] | page_height | The page height used for the converted PDF document (unit is 1/72 inch). This would be ignored if page mode com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_PageModeSinglePage is used.
  [in] | is_to_page_scale | (Deprecated)Used to decide whether to scale the converted PDF page or not.
  [in] | page_margin | The page margin used for converted PDF document.
  [in] | is_convert_link | Used to decide whether the web link should be converted or not.
  [in] | rotate_degrees | The rotation degree used for the converted PDF page.Please refer to values starting from com.foxit.sdk.common.Constants.e_Rotation0 and this should be one of these values.
  [in] | is_generate_tag | Used to decide whether the tag should be generated or not.
  [in] | page_mode | The page mode used for the converting. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_PageModeSinglePage and this should be one of these values.
  [in] | to_generate_bookmarks | Used to decide whether bookmarks should be generated or not.
  [in] | scaling_mode | The scaling mode used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_ScalingModeNone and this should be one of these values. Default value:com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_ScalingModeScale .
  [in] | encoding_format | The HTML encoding format Please refer to values starting from HTML2PDFEncodingFormat::e_EncodingFormatDefault and this should be one of these values.
  [in] | to_render_images | Whether to render images or not.
  [in] | to_remove_underline_for_link | Whether to remove underline decoration for link or not.
  [in] | to_set_headerfooter | Whether to set header-footer or not.
  [in] | headerfooter_title | The header-footer title which is content for center header.
  [in] | headerfooter_url | The header-footer url which is content for left footer.
  [in] | bookmark_root_name | The bookmark's root name.
  [in] | to_resize_objects | Whether to enable the Javascripts related resizing of the objects during rendering process.
  [in] | to_print_background | Whether to print background or not.
  [in] | to_optimize_tag_tree | Whether to optimize tag tree or not.
  [in] | media_style | The media style used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_MediaStyleScreen and this should be one of these values.
  [in] | to_load_active_content | Whether to load active content or not.
  [in] | to_disable_sandbox | Whether to disable sandbox or not.
  [in] | to_use_blacklist | Whether to use blacklist or not.
  [in] | to_hide_header | Whether to hide header or not.
  [in] | to_hide_footer | Whether to hide footer or not.
  [in] | to_deny_local_file_access | Whether to deny local file access or not.

Returns
  None.

## Member Function Documentation

## ◆ delete()

synchronized void com.foxit.sdk.addon.conversion.HTML2PDFSettingData.delete | ( |  | ) |

Clean up related C++ resources immediately.

Returns
  None.

Note
  Once this function is called, current object cannot be used anymore.

## ◆ getBookmark_root_name()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getBookmark_root_name | ( |  | ) |

Get the bookmark's root name.

Returns
  The bookmark's root name.

## ◆ getEncoding_format()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getEncoding_format | ( |  | ) |

Get the HTML encoding format Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_EncodingFormatDefault and this should be one of these values.

Returns
  The HTML encoding format Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_EncodingFormatDefault and this should be one of these values.

## ◆ getHeaderfooter_title()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getHeaderfooter_title | ( |  | ) |

Get the header-footer title which is content for center header.

Returns
  The header-footer title which is content for center header.

## ◆ getHeaderfooter_url()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getHeaderfooter_url | ( |  | ) |

Get the header-footer url which is content for left footer.

Returns
  The header-footer url which is content for left footer.

## ◆ getIs_convert_link()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getIs_convert_link | ( |  | ) |

Get used to decide whether the web link should be converted or not.

Returns
  Used to decide whether the web link should be converted or not.

## ◆ getIs_generate_tag()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getIs_generate_tag | ( |  | ) |

Get used to decide whether the tag should be generated or not.

Returns
  Used to decide whether the tag should be generated or not.

## ◆ getIs_to_page_scale()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getIs_to_page_scale | ( |  | ) |

Get used to decide whether to scale the converted PDF page or not.

Deprecated:
  Current property has been deprecated since Foxit PDF SDK 8.2. This property will not have any effect on converting PDF any more. For scaling mode, please refer to scaling_mode.

Returns
  Used to decide whether to scale the converted PDF page or not.

## ◆ getMedia_style()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getMedia_style | ( |  | ) |

Get the media style used for the converted PDF document.

Returns
  The media style used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_MediaStyleScreen and this should be one of these values.

## ◆ getPage_height()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getPage_height | ( |  | ) |

Get the page height used for the converted PDF document (unit is 1/72 inch).

This value minus the sum of the top and bottom margins must be bigger than 16.

Note
  The page height would be ignored if page mode com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_PageModeSinglePage is used.

Returns
  The page height used for the converted PDF document (unit is 1/72 inch).

## ◆ getPage_margin()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getPage_margin | ( |  | ) |

Get the page margin used for converted PDF document.

Note
  This value does not represent a rectangle. It just defines the left margin, bottom margin, right margin and top margin of a PDF page.

Returns
  The page margin used for converted PDF document.

## ◆ getPage_mode()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getPage_mode | ( |  | ) |

Get the page mode used for the converting.

Returns
  The page mode used for the converting. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_PageModeSinglePage and this should be one of these values.

## ◆ getPage_width()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getPage_width | ( |  | ) |

Get the page width used for the converted PDF document (unit is 1/72 inch).

This value minus the sum of the left and right margins must be bigger than 16.

Returns
  The page width used for the converted PDF document (unit is 1/72 inch).

## ◆ getRotate_degrees()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getRotate_degrees | ( |  | ) |

Get the rotation degree used for the converted PDF page.

Returns
  The rotation degree used for the converted PDF page.Please refer to values starting from com.foxit.sdk.common.Constants.e_Rotation0 and this should be one of these values.

## ◆ getScaling_mode()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getScaling_mode | ( |  | ) |

Get the scaling mode used for the converted PDF document.

Returns
  The scaling mode used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_ScalingModeNone and this should be one of these values.

## ◆ getTo_deny_local_file_access()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_deny_local_file_access | ( |  | ) |

Get used to decide whether to deny local file access or not during converting html file.

true means that prevents the HTML file from accessing any local files outside of its own directory. false means that allows the HTML file to access to any local file paths. Default value: false.

Returns
  Used to decide whether to deny local file access or not during converting html file. It can not support on Linux x86 platform.

## ◆ getTo_disable_sandbox()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_disable_sandbox | ( |  | ) |

Get used to decide whether to disable sandbox or not.

true means to disable sandbox, and false means not. Default: true.

Returns
  Used to decide whether to disable sandbox or not.

## ◆ getTo_generate_bookmarks()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_generate_bookmarks | ( |  | ) |

Get used to decide whether bookmarks should be generated or not.

Returns
  Used to decide whether bookmarks should be generated or not.

## ◆ getTo_hide_footer()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_hide_footer | ( |  | ) |

Get used to decide whether to hide footer or not.

Returns
  Used to decide whether to hide footer or not. It can not support on Linux x86 platform.

## ◆ getTo_hide_header()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_hide_header | ( |  | ) |

Get used to decide whether to hide header or not.

Returns
  Used to decide whether to hide header or not. It can not support on Linux x86 platform.

## ◆ getTo_load_active_content()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_load_active_content | ( |  | ) |

Get used to decide whether to load active content or not.

This parameter is useful for some optimized web pages. These web page will not load the entire content. When the user scrolls down the page, the contents of the web page will be loaded when they are displayed on the user screen. true means to load the active content that has not been loaded by the web page, and false means not. Default:false.

Returns
  Used to decide whether to load active content or not.

## ◆ getTo_optimize_tag_tree()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_optimize_tag_tree | ( |  | ) |

Get used to decide whether to optimize tag tree or not.

Returns
  Used to decide whether to optimize tag tree or not.

## ◆ getTo_print_background()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_print_background | ( |  | ) |

Get used to decide whether to print background or not.

Returns
  Used to decide whether to print background or not.

## ◆ getTo_remove_underline_for_link()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_remove_underline_for_link | ( |  | ) |

Get used to decide whether to remove underline decoration for link.

Returns
  Used to decide whether to remove underline decoration for link.

## ◆ getTo_render_images()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_render_images | ( |  | ) |

Get used to decide whether to render images or not.

Returns
  Used to decide whether to render images or not.

## ◆ getTo_resize_objects()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_resize_objects | ( |  | ) |

Get whether to enable the Javascripts related resizing of the objects during rendering process.

Returns
  Whether to enable the Javascripts related resizing of the objects during rendering process.

## ◆ getTo_set_headerfooter()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_set_headerfooter | ( |  | ) |

Get used to decide whether to set header-footer or not.

Returns
  Used to decide whether to set header-footer or not.

## ◆ getTo_use_blacklist()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.getTo_use_blacklist | ( |  | ) |

Get used to decide whether to use blacklist or not.

This parameter is useful for checking all accessed URLs during the HTML to the PDF conversion process.
During the conversion of specific URL, there could be many third-party websites that are accessed by the conversion process (images, CSS styles, requests from JavaScripts, and others).
All of these accesses will be checked against the blacklist record. There is a prepared switch that enables the blacklist functionality in the converter. true means to use the blacklist, and false means not. Default: false. Blacklist JSON is located next to the fxhtml2pdf application and its name must be "blacklist.json".It consist from three parts of records:

- list of domains.

- list of IPs.

- list of IP ranges.

"blacklist.json" Examples:

             {"Domains":[
                  "xxx.com",
                  "xxx.com"
                  ]
              ,
             "IPs":["1.2.3.4","5.6.7.8"]
             ,
             "IPsegments":[{"16":["104.193.88.0","104.193.88.100"]},{"16":["20.0.0.1","20.0.0.10"]}]
             }

Returns
  Used to decide whether to use blacklist or not.

## ◆ set()

void com.foxit.sdk.addon.conversion.HTML2PDFSettingData.set | ( | float | page_width,
|  | float | page_height,
|  | boolean | is_to_page_scale,
|  | RectF | page_margin,
|  | boolean | is_convert_link,
|  | int | rotate_degrees,
|  | boolean | is_generate_tag,
|  | int | page_mode,
|  | boolean | to_generate_bookmarks,
|  | int | scaling_mode,
|  | int | encoding_format,
|  | boolean | to_render_images,
|  | boolean | to_remove_underline_for_link,
|  | boolean | to_set_headerfooter,
|  | String | headerfooter_title,
|  | String | headerfooter_url,
|  | String | bookmark_root_name,
|  | boolean | to_resize_objects,
|  | boolean | to_print_background,
|  | boolean | to_optimize_tag_tree,
|  | int | media_style,
|  | boolean | to_load_active_content,
|  | boolean | to_disable_sandbox,
|  | boolean | to_use_blacklist,
|  | boolean | to_hide_header,
|  | boolean | to_hide_footer,
|  | boolean | to_deny_local_file_access
| ) |  |

Set value.

Parameters

  [in] | page_width | The page width used for the converted PDF document (unit is 1/72 inch).
  [in] | page_height | The page height used for the converted PDF document (unit is 1/72 inch). This would be ignored if page mode com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_PageModeSinglePage is used.
  [in] | is_to_page_scale | (Deprecated)Used to decide whether to scale the converted PDF page or not.
  [in] | page_margin | The page margin used for converted PDF document.
  [in] | is_convert_link | Used to decide whether the web link should be converted or not.
  [in] | rotate_degrees | The rotation degree used for the converted PDF page.Please refer to values starting from com.foxit.sdk.common.Constants.e_Rotation0 and this should be one of these values.
  [in] | is_generate_tag | Used to decide whether the tag should be generated or not.
  [in] | page_mode | The page mode used for the converting. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_PageModeSinglePage and this should be one of these values.
  [in] | to_generate_bookmarks | Used to decide whether bookmarks should be generated or not.
  [in] | scaling_mode | The scaling mode used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_ScalingModeNone and this should be one of these values.Default value:HTML2PDFSettingData::e_PageScalingScale.
  [in] | encoding_format | The HTML encoding format Please refer to values starting from HTML2PDFEncodingFormat::e_EncodingFormatDefault and this should be one of these values.
  [in] | to_render_images | Whether to render images or not.
  [in] | to_remove_underline_for_link | Whether to remove underline decoration for link or not.
  [in] | to_set_headerfooter | Whether to set header-footer or not.
  [in] | headerfooter_title | The header-footer title which is content for center header.
  [in] | headerfooter_url | The header-footer url which is content for left footer.
  [in] | bookmark_root_name | The bookmark's root name.
  [in] | to_resize_objects | Whether to enable the Javascripts related resizing of the objects during rendering process.
  [in] | to_print_background | Whether to print background or not.
  [in] | to_optimize_tag_tree | Whether to optimize tag tree or not.
  [in] | media_style | The media style used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_MediaStyleScreen and this should be one of these values.
  [in] | to_load_active_content | Whether to load active content or not.
  [in] | to_disable_sandbox | Whether to disable sandbox or not.
  [in] | to_use_blacklist | Whether to use blacklist or not.
  [in] | to_hide_header | Whether to hide header or not.
  [in] | to_hide_footer | Whether to hide footer or not.
  [in] | to_deny_local_file_access | Whether to deny local file access or not.

Returns
  None.

## ◆ setBookmark_root_name()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setBookmark_root_name | ( | String | value | ) |

Set the bookmark's root name.

Parameters

  [in] | value | The bookmark's root name.

Returns
  None.

## ◆ setEncoding_format()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setEncoding_format | ( | int | value | ) |

Set the HTML encoding format Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_EncodingFormatDefault and this should be one of these values.

Parameters

  [in] | value | The HTML encoding format Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_EncodingFormatDefault and this should be one of these values.

Returns
  None.

## ◆ setHeaderfooter_title()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setHeaderfooter_title | ( | String | value | ) |

Set the header-footer title which is content for center header.

Parameters

  [in] | value | The header-footer title which is content for center header.

Returns
  None.

## ◆ setHeaderfooter_url()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setHeaderfooter_url | ( | String | value | ) |

Set the header-footer url which is content for left footer.

Parameters

  [in] | value | The header-footer url which is content for left footer.

Returns
  None.

## ◆ setIs_convert_link()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setIs_convert_link | ( | boolean | value | ) |

Set used to decide whether the web link should be converted or not.

Parameters

  [in] | value | Used to decide whether the web link should be converted or not.

Returns
  None.

## ◆ setIs_generate_tag()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setIs_generate_tag | ( | boolean | value | ) |

Set used to decide whether the tag should be generated or not.

Parameters

  [in] | value | Used to decide whether the tag should be generated or not.

Returns
  None.

## ◆ setIs_to_page_scale()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setIs_to_page_scale | ( | boolean | value | ) |

Set used to decide whether to scale the converted PDF page or not.

Deprecated:
  Current property has been deprecated since Foxit PDF SDK 8.2. This property will not have any effect on converting PDF any more. For scaling mode, please refer to scaling_mode.

Parameters

  [in] | value | Used to decide whether to scale the converted PDF page or not.

Returns
  None.

## ◆ setMedia_style()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setMedia_style | ( | int | value | ) |

Set the media style used for the converted PDF document.

Parameters

  [in] | value | The media style used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_MediaStyleScreen and this should be one of these values.

Returns
  None.

## ◆ setPage_height()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setPage_height | ( | float | value | ) |

Set the page height used for the converted PDF document (unit is 1/72 inch).

This value minus the sum of the top and bottom margins must be bigger than 16.

Note
  The page height would be ignored if page mode com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_PageModeSinglePage is used.

Parameters

  [in] | value | The page height used for the converted PDF document (unit is 1/72 inch).

Returns
  None.

## ◆ setPage_margin()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setPage_margin | ( | RectF | value | ) |

Set the page margin used for converted PDF document.

Note
  This value does not represent a rectangle. It just defines the left margin, bottom margin, right margin and top margin of a PDF page.

Parameters

  [in] | value | The page margin used for converted PDF document.

Returns
  None.

## ◆ setPage_mode()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setPage_mode | ( | int | value | ) |

Set the page mode used for the converting.

Parameters

  [in] | value | The page mode used for the converting. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_PageModeSinglePage and this should be one of these values.

Returns
  None.

## ◆ setPage_width()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setPage_width | ( | float | value | ) |

Set the page width used for the converted PDF document (unit is 1/72 inch).

This value minus the sum of the left and right margins must be bigger than 16.

Parameters

  [in] | value | The page width used for the converted PDF document (unit is 1/72 inch).

Returns
  None.

## ◆ setRotate_degrees()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setRotate_degrees | ( | int | value | ) |

Set the rotation degree used for the converted PDF page.

Parameters

  [in] | value | The rotation degree used for the converted PDF page.Please refer to values starting from com.foxit.sdk.common.Constants.e_Rotation0 and this should be one of these values.

Returns
  None.

## ◆ setScaling_mode()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setScaling_mode | ( | int | value | ) |

Set the scaling mode used for the converted PDF document.

Parameters

  [in] | value | The scaling mode used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.HTML2PDFSettingData.e_ScalingModeNone and this should be one of these values.

Returns
  None.

## ◆ setTo_deny_local_file_access()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_deny_local_file_access | ( | boolean | value | ) |

Set used to decide whether to deny local file access or not during converting html file.

true means that prevents the HTML file from accessing any local files outside of its own directory. false means that allows the HTML file to access to any local file paths. Default value: false.

Parameters

  [in] | value | Used to decide whether to deny local file access or not during converting html file. It can not support on Linux x86 platform.

Returns
  None.

## ◆ setTo_disable_sandbox()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_disable_sandbox | ( | boolean | value | ) |

Set used to decide whether to disable sandbox or not.

true means to disable sandbox, and false means not. Default: true.

Parameters

  [in] | value | Used to decide whether to disable sandbox or not.

Returns
  None.

## ◆ setTo_generate_bookmarks()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_generate_bookmarks | ( | boolean | value | ) |

Set used to decide whether bookmarks should be generated or not.

Parameters

  [in] | value | Used to decide whether bookmarks should be generated or not.

Returns
  None.

## ◆ setTo_hide_footer()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_hide_footer | ( | boolean | value | ) |

Set used to decide whether to hide footer or not.

Parameters

  [in] | value | Used to decide whether to hide footer or not. It can not support on Linux x86 platform.

Returns
  None.

## ◆ setTo_hide_header()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_hide_header | ( | boolean | value | ) |

Set used to decide whether to hide header or not.

Parameters

  [in] | value | Used to decide whether to hide header or not. It can not support on Linux x86 platform.

Returns
  None.

## ◆ setTo_load_active_content()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_load_active_content | ( | boolean | value | ) |

Set used to decide whether to load active content or not.

This parameter is useful for some optimized web pages. These web page will not load the entire content. When the user scrolls down the page, the contents of the web page will be loaded when they are displayed on the user screen. true means to load the active content that has not been loaded by the web page, and false means not. Default:false.

Parameters

  [in] | value | Used to decide whether to load active content or not.

Returns
  None.

## ◆ setTo_optimize_tag_tree()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_optimize_tag_tree | ( | boolean | value | ) |

Set used to decide whether to optimize tag tree or not.

Parameters

  [in] | value | Used to decide whether to optimize tag tree or not.

Returns
  None.

## ◆ setTo_print_background()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_print_background | ( | boolean | value | ) |

Set used to decide whether to print background or not.

Parameters

  [in] | value | Used to decide whether to print background or not.

Returns
  None.

## ◆ setTo_remove_underline_for_link()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_remove_underline_for_link | ( | boolean | value | ) |

Set used to decide whether to remove underline decoration for link.

Parameters

  [in] | value | Used to decide whether to remove underline decoration for link.

Returns
  None.

## ◆ setTo_render_images()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_render_images | ( | boolean | value | ) |

Set used to decide whether to render images or not.

Parameters

  [in] | value | Used to decide whether to render images or not.

Returns
  None.

## ◆ setTo_resize_objects()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_resize_objects | ( | boolean | value | ) |

Set whether to enable the Javascripts related resizing of the objects during rendering process.

Parameters

  [in] | value | Whether to enable the Javascripts related resizing of the objects during rendering process.

Returns
  None.

## ◆ setTo_set_headerfooter()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_set_headerfooter | ( | boolean | value | ) |

Set used to decide whether to set header-footer or not.

Parameters

  [in] | value | Used to decide whether to set header-footer or not.

Returns
  None.

## ◆ setTo_use_blacklist()

com.foxit.sdk.addon.conversion.HTML2PDFSettingData.setTo_use_blacklist | ( | boolean | value | ) |

Set used to decide whether to use blacklist or not.

This parameter is useful for checking all accessed URLs during the HTML to the PDF conversion process.
During the conversion of specific URL, there could be many third-party websites that are accessed by the conversion process (images, CSS styles, requests from JavaScripts, and others).
All of these accesses will be checked against the blacklist record. There is a prepared switch that enables the blacklist functionality in the converter. true means to use the blacklist, and false means not. Default: false. Blacklist JSON is located next to the fxhtml2pdf application and its name must be "blacklist.json".It consist from three parts of records:

- list of domains.

- list of IPs.

- list of IP ranges.

"blacklist.json" Examples:

             {"Domains":[
                  "xxx.com",
                  "xxx.com"
                  ]
              ,
             "IPs":["1.2.3.4","5.6.7.8"]
             ,
             "IPsegments":[{"16":["104.193.88.0","104.193.88.100"]},{"16":["20.0.0.1","20.0.0.10"]}]
             }

Parameters

  [in] | value | Used to decide whether to use blacklist or not.

Returns
  None.