Foxit PDF SDK
com.foxit.sdk.addon.conversion.DWG2PDFSettingData Class Reference

Public Member Functions

 DWG2PDFSettingData ()
 Constructor, with parameters.

 
synchronized void delete ()
 Clean up related C++ resources immediately. More...
 
int getBackground_color_index ()
 Get background color index in the CAD color palette (range: [0-255]). More...
 
int getColor_image_output_dpi ()
 Get color image output DPI setting. More...
 
int getColor_policy ()
 Get the color policy used for the converted PDF document. More...
 
String getDrawing_size_block_reference_name ()
 Get the Name of the block reference used to compute drawing scale. More...
 
boolean getEnable_diagnostic_log_output ()
 Get whether to output DWG2PDF diagnostic logs. More...
 
int getExport_flags ()
 Get the export flags used for the converted PDF document. More...
 
int getExport_hatches_type ()
 Get the type of solid hatches export. More...
 
String getFrame_block_configuration_path ()
 Get frame block configuration XML path for frame-block export mode. More...
 
int getGeometry_output_dpi ()
 Get geometry output DPI setting. More...
 
int getGradient_export_hatches_type ()
 Get the type of gradient hatches export. More...
 
boolean getIs_active_layout ()
 Get true means to export the active layout only, while false means not. More...
 
boolean getIs_output_progress ()
 Get a boolean value which indicates whether to output progress logs. More...
 
int getLayout_index ()
 Get layout index used when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeLayoutByIndex . More...
 
int getLayout_scope ()
 Get layout export scope. More...
 
double getLineweight_scale_factor ()
 Get lineweight scale factor. More...
 
int getLineweight_style_mode ()
 Get plot lineweight style mode. More...
 
double getMaximum_drawing_area ()
 Get maximum allowed drawing frame area (unit is millimeters). More...
 
double getMinimum_export_rect_side_length ()
 Get minimum drawing frame side length used by auto-rectangle export (unit is millimeters). More...
 
int getMonochrome_image_output_dpi ()
 Get monochrome image output DPI setting. More...
 
int getOther_export_hatches_type ()
 Get the type of other (non-solid) hatches export. More...
 
String getOutput_author ()
 Get the author for the output PDF document, an empty string will be used as default. More...
 
String getOutput_creator ()
 Get the creator for the output PDF document, an empty string will be used as default. More...
 
String getOutput_keywords ()
 Get the keywords for the output PDF document, an empty string will be used as default. More...
 
String getOutput_producer ()
 Get the producer for the output PDF document, an empty string will be used as default. More...
 
String getOutput_subject ()
 Get the subject for the output PDF document, an empty string will be used as default. More...
 
String getOutput_title ()
 Get the title for the output PDF document, an empty string will be used as default. More...
 
int getPage_margin ()
 Get page margin (unit is millimeters). More...
 
float getPaper_height ()
 Get the paper height used for the converted PDF document. More...
 
float getPaper_width ()
 Get the paper width used for the converted PDF document. More...
 
double getPlot_scale_factor ()
 Get plot scale factor. More...
 
java.lang.Object getProgress_callback ()
 Get a pointer to a DWG2PDFProgressCallback object which is used to receive the progress of converting DWG to PDF. More...
 
int getSearchable_text_type ()
 Get the type of search text type. More...
 
boolean getTreat_inches_as_millimeters ()
 Get whether to treat inch-based dimensions as millimeters. More...
 
void setBackground_color_index (int value)
 Set background color index in the CAD color palette (range: [0-255]). More...
 
void setColor_image_output_dpi (int value)
 Set color image output DPI setting. More...
 
void setColor_policy (int value)
 Set the color policy used for the converted PDF document. More...
 
void setDrawing_size_block_reference_name (String value)
 Set the Name of the block reference used to compute drawing scale. More...
 
void setEnable_diagnostic_log_output (boolean value)
 Set whether to output DWG2PDF diagnostic logs. More...
 
void setExport_flags (int value)
 Set the export flags used for the converted PDF document. More...
 
void setExport_hatches_type (int value)
 Set the type of solid hatches export. More...
 
void setFrame_block_configuration_path (String value)
 Set frame block configuration XML path for frame-block export mode. More...
 
void setGeometry_output_dpi (int value)
 Set geometry output DPI setting. More...
 
void setGradient_export_hatches_type (int value)
 Set the type of gradient hatches export. More...
 
void setIs_active_layout (boolean value)
 Set true means to export the active layout only, while false means not. More...
 
void setIs_output_progress (boolean value)
 Set a boolean value which indicates whether to output progress logs. More...
 
void setLayout_index (int value)
 Set layout index used when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeLayoutByIndex . More...
 
void setLayout_scope (int value)
 Set layout export scope. More...
 
void setLineweight_scale_factor (double value)
 Set lineweight scale factor. More...
 
void setLineweight_style_mode (int value)
 Set plot lineweight style mode. More...
 
void setMaximum_drawing_area (double value)
 Set maximum allowed drawing frame area (unit is millimeters). More...
 
void setMinimum_export_rect_side_length (double value)
 Set minimum drawing frame side length used by auto-rectangle export (unit is millimeters). More...
 
void setMonochrome_image_output_dpi (int value)
 Set monochrome image output DPI setting. More...
 
void setOther_export_hatches_type (int value)
 Set the type of other (non-solid) hatches export. More...
 
void setOutput_author (String value)
 Set the author for the output PDF document, an empty string will be used as default. More...
 
void setOutput_creator (String value)
 Set the creator for the output PDF document, an empty string will be used as default. More...
 
void setOutput_keywords (String value)
 Set the keywords for the output PDF document, an empty string will be used as default. More...
 
void setOutput_producer (String value)
 Set the producer for the output PDF document, an empty string will be used as default. More...
 
void setOutput_subject (String value)
 Set the subject for the output PDF document, an empty string will be used as default. More...
 
void setOutput_title (String value)
 Set the title for the output PDF document, an empty string will be used as default. More...
 
void setPage_margin (int value)
 Set page margin (unit is millimeters). More...
 
void setPaper_height (float value)
 Set the paper height used for the converted PDF document. More...
 
void setPaper_width (float value)
 Set the paper width used for the converted PDF document. More...
 
void setPlot_scale_factor (double value)
 Set plot scale factor. More...
 
void setProgress_callback (java.lang.Object value)
 Set a pointer to a DWG2PDFProgressCallback object which is used to receive the progress of converting DWG to PDF. More...
 
void setSearchable_text_type (int value)
 Set the type of search text type. More...
 
void setTreat_inches_as_millimeters (boolean value)
 Set whether to treat inch-based dimensions as millimeters. More...
 

Static Public Attributes

static final int e_DWG2PDFColorPolicyGrayscale = 2
 Color policy: Drawing is exported to a grayscale PDF file. Native colors are converted into grayscale.

 
static final int e_DWG2PDFColorPolicyIndexToBlack = 3
 Color policy: Index colors are converted to black, while all other colors keep their object colors.

 
static final int e_DWG2PDFColorPolicyMono = 1
 Color policy: Drawing is exported to a monochrome PDF file.

 
static final int e_DWG2PDFColorPolicyNoPolicy = 0
 Color policy: No color policy. A drawing is exported with its native color palette (as is).

 
static final int e_DWG2PDFExportHatchesTypeBitmap = 0
 Hatches export type: Exports hatch as a bitmap.

 
static final int e_DWG2PDFExportHatchesTypeDrawing = 1
 Hatches export type: Exports hatch as a set of triangles (vectorizer).

 
static final int e_DWG2PDFExportHatchesTypePdfPaths = 2
 Hatches export type: Exports hatch as a PDF path (solid hatches only).

 
static final int e_DWG2PDFExportHatchesTypePolygons = 3
 Hatches export type: Exports hatch as a polygon (solid hatches only).

 
static final int e_DWG2PDFLayoutScopeAllLayouts = 2
 Export all layouts.

 
static final int e_DWG2PDFLayoutScopeAutoByLayoutOverflow = 6
 Auto-select layouts or model space based on viewport overflow check.

 
static final int e_DWG2PDFLayoutScopeAutoRects = 7
 Auto-detect and export multiple rectangles in model space.

 
static final int e_DWG2PDFLayoutScopeAutoRectsAndAllLayouts = 9
 Merge results of com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects and com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAllLayouts into one PDF.

 
static final int e_DWG2PDFLayoutScopeCurrentLayout = 1
 Export current layout.

 
static final int e_DWG2PDFLayoutScopeDrawingLimits = 5
 Export drawing limits.

 
static final int e_DWG2PDFLayoutScopeFrameBlocks = 4
 Export configured frame blocks in model space as multiple PDF pages.
More...
 
static final int e_DWG2PDFLayoutScopeLayoutByIndex = 8
 Export a specific layout by index, specified by DWG2PDFSettingData.getLayout_index .

 
static final int e_DWG2PDFLayoutScopeModelSpaceAndLayouts = 3
 Export model space and all valid layouts.

 
static final int e_DWG2PDFLayoutScopeModelSpaceOnly = 0
 Export model space only.

 
static final int e_DWG2PDFLineweightStyleModeNoStyleNoLineweight = 0
 Ignore plot style and lineweight.

 
static final int e_DWG2PDFLineweightStyleModeStyleAndLineweight = 1
 Enable plot style and lineweight.

 
static final int e_DWG2PDFLineweightStyleModeStyleNoLineweight = 2
 Enable plot style and ignore lineweight.

 
static final int e_DWG2PDFSearchableTextTypeNoSearch = 0
 Searchable text type: No searchable text.

 
static final int e_DWG2PDFSearchableTextTypeSHX = 1
 Searchable text type: Only text displayed with SHX font is searchable.

 
static final int e_DWG2PDFSearchableTextTypeTTF = 2
 Searchable text type: Only text displayed with TTF font is searchable.

 
static final int e_FlagASCIIHexEncoding = 0x0200
 Bit 10. Enable ASCIIHex encoding of internal PDF streams.

 
static final int e_FlagEmbededOptimizedTTF = 0x0040
 Bit 7. Enable embedding of TTF font program to PDF file. The TTF font will be reduced by removing unused parts (smaller PDF file size, but limited editing).

 
static final int e_FlagEmbededTTF = 0x0001
 Bit 1. Enable embedding of TTF(True Type Font) program to PDF file. The whole TTF font file will be embedded (huge PDF size).

 
static final int e_FlagEnableLayers = 0x0010
 Bit 5. If enabled, layer support will be added to PDF file (1.5 version required).

 
static final int e_FlagExportHyperlinks = 0x0400
 Bit 11. Enable hyperlinks export.

 
static final int e_FlagFlateCompression = 0x0100
 Bit 9. Enable compression of internal PDF streams.

 
static final int e_FlagIncludeOffLayers = 0x0020
 Bit 6. If enabled, invisible layers will be added to PDF file (1.5 version required).

 
static final int e_FlagLinearized = 0x1000
 Bit 13. Create linearized PDF file.

 
static final int e_FlagMeasuring = 0x4000
 Bit 15. Enable measuring scale in pdf.

 
static final int e_FlagSHXTextAsGeometry = 0x0004
 Bit 3. Enable SHX font text to geometry conversion.

 
static final int e_FlagSimpleGeomOptimization = 0x0008
 Bit 4. Enable simple geometry optimization (separated segments to one polyline, Bezier curve control points).

 
static final int e_FlagTTFTextAsGeometry = 0x0002
 Bit 2. Enable TTF font text to geometry conversion.

 
static final int e_FlagUseHLR = 0x0080
 Bit 8. Determines whether software uses vector hidden-line removal for corresponding viewports.

 
static final int e_FlagZoomToExtentsMode = 0x0800
 Bit 12. If enabled, layout geometry will be zoomed to paper size, else layout settings will be applied.
More...
 

Detailed Description

This class represents settings used for converting DWG to PDF. This would be used in class Convert .

See also
Convert

Member Function Documentation

◆ delete()

synchronized void com.foxit.sdk.addon.conversion.DWG2PDFSettingData.delete ( )

Clean up related C++ resources immediately.

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

◆ getBackground_color_index()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getBackground_color_index ( )

Get background color index in the CAD color palette (range: [0-255]).

Default value: 7. Common indices: 0-black, 1-red, 2-yellow, 3-green, 4-aqua, 5-blue, 6-magenta, 7-white, 8-dark gray. Other values follow the standard CAD color palette definitions. Values outside the range [0-255] are normalized to 7.

Returns
Background color index in the CAD color palette (range: [0-255]).

◆ getColor_image_output_dpi()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getColor_image_output_dpi ( )

Get color image output DPI setting.

Default value: 400. Valid values are 72, 150, 200, 300, 400, 600 and 1200. Values outside this set are normalized to 400.

Returns
Color image output DPI setting.

◆ getColor_policy()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getColor_policy ( )

Get the color policy used for the converted PDF document.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFColorPolicyNoPolicy as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFColorPolicyNoPolicy and this should be one of these values.

Returns
The color policy used for the converted PDF document.

◆ getDrawing_size_block_reference_name()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getDrawing_size_block_reference_name ( )

Get the Name of the block reference used to compute drawing scale.

This option is effective only when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects . The block is treated as the drawing frame, and its original size is used to determine a scale factor applied during PDF export. If the specified block does not exist, this option will not take effect.

Returns
The Name of the block reference used to compute drawing scale.

◆ getEnable_diagnostic_log_output()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getEnable_diagnostic_log_output ( )

Get whether to output DWG2PDF diagnostic logs.

Default value is false. false means disabled, and true means enabled.

Returns
Whether to output DWG2PDF diagnostic logs.

◆ getExport_flags()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getExport_flags ( )

Get the export flags used for the converted PDF document.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagEmbededTTF as the default value of this option.

Returns
The export flags used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagEmbededTTF and this can be one or a combination of these values It could also be 0, which means all bits in the flag are 0.

◆ getExport_hatches_type()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getExport_hatches_type ( )

Get the type of solid hatches export.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypePolygons as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and this should be one of these values.

Returns
The type of solid hatches export.

◆ getFrame_block_configuration_path()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getFrame_block_configuration_path ( )

Get frame block configuration XML path for frame-block export mode.

This file should contain configured title block names in format:

         <?xml version="1.0" encoding="utf-8" ?>
         <root>
         <TitleBlock name="Frame1">
         <TitleBlock name="Frame2">
         </root>
         

This option is mainly used when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeFrameBlocks . The XML file name is not restricted. Empty string means no external frame-block configuration file is used.

Returns
Frame block configuration XML path for frame-block export mode.

◆ getGeometry_output_dpi()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getGeometry_output_dpi ( )

Get geometry output DPI setting.

Default value: 400. Valid values are 72, 150, 200, 300, 400, 600 and 1200. Values outside this set are normalized to 400.

Returns
Geometry output DPI setting.

◆ getGradient_export_hatches_type()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getGradient_export_hatches_type ( )

Get the type of gradient hatches export.

For this option, only com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeDrawing are supported. It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and this should be one of these values

Returns
The type of gradient hatches export.

◆ getIs_active_layout()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getIs_active_layout ( )

Get true means to export the active layout only, while false means not.

Deprecated:
This property has been deprecated. Please use DWG2PDFSettingData.getLayout_scope instead. Setting DWG2PDFSettingData.getLayout_scope to com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeCurrentLayout provides the same behavior as setting current property to true.
Returns
true means to export the active layout only, while false means not. Default value: false.

◆ getIs_output_progress()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getIs_output_progress ( )

Get a boolean value which indicates whether to output progress logs.

Returns
A boolean value which indicates whether to output progress logs. true means to output progress logs, and false means not. Default value: true.

◆ getLayout_index()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getLayout_index ( )

Get layout index used when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeLayoutByIndex .

The Default value is 1 (the first layout). Values less than 1 are normalized to 1 when using layout by index mode. This option is ignored for other layout scope modes.

Returns
Layout index used when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeLayoutByIndex .

◆ getLayout_scope()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getLayout_scope ( )

Get layout export scope.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeCurrentLayout as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeModelSpaceOnly . When set to com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeLayoutByIndex , use DWG2PDFSettingData.getLayout_index to specify the target layout index. If an unsupported value is provided, it is normalized to com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeCurrentLayout mode.

Returns
Layout export scope.

◆ getLineweight_scale_factor()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getLineweight_scale_factor ( )

Get lineweight scale factor.

Default value: 1.0. This option is effective only when DWG2PDFSettingData.getLineweight_style_mode is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLineweightStyleModeStyleAndLineweight . Values less than or equal to 0 are treated as 1.0.

Returns
Lineweight scale factor.

◆ getLineweight_style_mode()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getLineweight_style_mode ( )

Get plot lineweight style mode.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLineweightStyleModeNoStyleNoLineweight as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLineweightStyleModeNoStyleNoLineweight . If an unsupported value is provided, an com.foxit.sdk.common.Constants.e_ErrParam error will be thrown.

Returns
Plot lineweight style mode.

◆ getMaximum_drawing_area()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getMaximum_drawing_area ( )

Get maximum allowed drawing frame area (unit is millimeters).

Default value is 0. This option is effective only when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects or com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRectsAndAllLayouts . If a drawing frame's area exceeds this value, it will be scaled down to fit within the limit. A value of 0 means no limit. Negative values will be treated as 0.

Returns
Maximum allowed drawing frame area (unit is millimeters).

◆ getMinimum_export_rect_side_length()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getMinimum_export_rect_side_length ( )

Get minimum drawing frame side length used by auto-rectangle export (unit is millimeters).

Default value is 0. This option is effective only when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects . In this mode, any drawing frame whose width or height is smaller than this value will be skipped. If this value exceeds the maximum side length of all detected drawing frames, all frames will be skipped. A value of 0 means no limit. Negative values will be treated as 0.

Returns
Minimum drawing frame side length used by auto-rectangle export (unit is millimeters).

◆ getMonochrome_image_output_dpi()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getMonochrome_image_output_dpi ( )

Get monochrome image output DPI setting.

Default value: 400. Valid values are 72, 150, 200, 300, 400, 600 and 1200. Values outside this set are normalized to 400.

Returns
Monochrome image output DPI setting.

◆ getOther_export_hatches_type()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getOther_export_hatches_type ( )

Get the type of other (non-solid) hatches export.

For this option, only com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeDrawing are supported. It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and this should be one of these values

Returns
The type of other (non-solid) hatches export.

◆ getOutput_author()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getOutput_author ( )

Get the author for the output PDF document, an empty string will be used as default.

Returns
The author for the output PDF document, an empty string will be used as default.

◆ getOutput_creator()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getOutput_creator ( )

Get the creator for the output PDF document, an empty string will be used as default.

Returns
The creator for the output PDF document, an empty string will be used as default.

◆ getOutput_keywords()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getOutput_keywords ( )

Get the keywords for the output PDF document, an empty string will be used as default.

Returns
The keywords for the output PDF document, an empty string will be used as default.

◆ getOutput_producer()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getOutput_producer ( )

Get the producer for the output PDF document, an empty string will be used as default.

Returns
The producer for the output PDF document, an empty string will be used as default.

◆ getOutput_subject()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getOutput_subject ( )

Get the subject for the output PDF document, an empty string will be used as default.

Returns
The subject for the output PDF document, an empty string will be used as default.

◆ getOutput_title()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getOutput_title ( )

Get the title for the output PDF document, an empty string will be used as default.

Returns
The title for the output PDF document, an empty string will be used as default.

◆ getPage_margin()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getPage_margin ( )

Get page margin (unit is millimeters).

Default value: 0. Negative values are treated as 0. Values exceeding half of the page size will be set to less than half of the page size.

Returns
Page margin (unit is millimeters).

◆ getPaper_height()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getPaper_height ( )

Get the paper height used for the converted PDF document.

This option can be used if layout geometry will be zoomed to paper size(com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagZoomToExtentsMode are enabled by export_flags). Effective default value is 297.0f. Unit: millimeters. If this value is less than or equal to 0, it is normalized to 297.0f.

Returns
The paper height used for the converted PDF document.

◆ getPaper_width()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getPaper_width ( )

Get the paper width used for the converted PDF document.

This option can be used if layout geometry will be zoomed to paper size(com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagZoomToExtentsMode are enabled by export_flags). Effective default value is 420.0f. Unit: millimeters. If this value is less than or equal to 0, it is normalized to 420.0f.

Returns
The paper width used for the converted PDF document.

◆ getPlot_scale_factor()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getPlot_scale_factor ( )

Get plot scale factor.

Default value is 0.99. No strict upper bound is enforced for this value. However, invalid inputs are normalized to maintain stable output. Values less than 0 are normalized to 0.1, and 0 is normalized to 0.99.

Returns
Plot scale factor.

◆ getProgress_callback()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getProgress_callback ( )

Get a pointer to a DWG2PDFProgressCallback object which is used to receive the progress of converting DWG to PDF.

Returns
A pointer to a DWG2PDFProgressCallback object which is used to receive the progress of converting DWG to PDF. This parameter can be null.

◆ getSearchable_text_type()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getSearchable_text_type ( )

Get the type of search text type.

This option can be used if SHX or TTF text exported as geometry(com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagTTFTextAsGeometry and com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagSHXTextAsGeometry are enabled by export_flags). It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFSearchableTextTypeNoSearch as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFSearchableTextTypeNoSearch and this should be one of these values.

Returns
The type of search text type.

◆ getTreat_inches_as_millimeters()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.getTreat_inches_as_millimeters ( )

Get whether to treat inch-based dimensions as millimeters.

Default value is false. This option is effective only when the drawing uses inches as its unit and DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects . false means disabled, and true means enabled.

Returns
Whether to treat inch-based dimensions as millimeters.

◆ setBackground_color_index()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setBackground_color_index ( int  value)

Set background color index in the CAD color palette (range: [0-255]).

Default value: 7. Common indices: 0-black, 1-red, 2-yellow, 3-green, 4-aqua, 5-blue, 6-magenta, 7-white, 8-dark gray. Other values follow the standard CAD color palette definitions. Values outside the range [0-255] are normalized to 7.

Parameters
[in]valueBackground color index in the CAD color palette (range: [0-255]).
Returns
None.

◆ setColor_image_output_dpi()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setColor_image_output_dpi ( int  value)

Set color image output DPI setting.

Default value: 400. Valid values are 72, 150, 200, 300, 400, 600 and 1200. Values outside this set are normalized to 400.

Parameters
[in]valueColor image output DPI setting.
Returns
None.

◆ setColor_policy()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setColor_policy ( int  value)

Set the color policy used for the converted PDF document.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFColorPolicyNoPolicy as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFColorPolicyNoPolicy and this should be one of these values.

Parameters
[in]valueThe color policy used for the converted PDF document.
Returns
None.

◆ setDrawing_size_block_reference_name()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setDrawing_size_block_reference_name ( String  value)

Set the Name of the block reference used to compute drawing scale.

This option is effective only when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects . The block is treated as the drawing frame, and its original size is used to determine a scale factor applied during PDF export. If the specified block does not exist, this option will not take effect.

Parameters
[in]valueThe Name of the block reference used to compute drawing scale.
Returns
None.

◆ setEnable_diagnostic_log_output()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setEnable_diagnostic_log_output ( boolean  value)

Set whether to output DWG2PDF diagnostic logs.

Default value is false. false means disabled, and true means enabled.

Parameters
[in]valueWhether to output DWG2PDF diagnostic logs.
Returns
None.

◆ setExport_flags()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setExport_flags ( int  value)

Set the export flags used for the converted PDF document.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagEmbededTTF as the default value of this option.

Parameters
[in]valueThe export flags used for the converted PDF document. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagEmbededTTF and this can be one or a combination of these values It could also be 0, which means all bits in the flag are 0.
Returns
None.

◆ setExport_hatches_type()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setExport_hatches_type ( int  value)

Set the type of solid hatches export.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypePolygons as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and this should be one of these values.

Parameters
[in]valueThe type of solid hatches export.
Returns
None.

◆ setFrame_block_configuration_path()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setFrame_block_configuration_path ( String  value)

Set frame block configuration XML path for frame-block export mode.

This file should contain configured title block names in format:

         <?xml version="1.0" encoding="utf-8" ?>
         <root>
         <TitleBlock name="Frame1">
         <TitleBlock name="Frame2">
         </root>
         

This option is mainly used when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeFrameBlocks . The XML file name is not restricted. Empty string means no external frame-block configuration file is used.

Parameters
[in]valueFrame block configuration XML path for frame-block export mode.
Returns
None.

◆ setGeometry_output_dpi()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setGeometry_output_dpi ( int  value)

Set geometry output DPI setting.

Default value: 400. Valid values are 72, 150, 200, 300, 400, 600 and 1200. Values outside this set are normalized to 400.

Parameters
[in]valueGeometry output DPI setting.
Returns
None.

◆ setGradient_export_hatches_type()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setGradient_export_hatches_type ( int  value)

Set the type of gradient hatches export.

For this option, only com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeDrawing are supported. It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and this should be one of these values

Parameters
[in]valueThe type of gradient hatches export.
Returns
None.

◆ setIs_active_layout()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setIs_active_layout ( boolean  value)

Set true means to export the active layout only, while false means not.

Deprecated:
This property has been deprecated. Please use DWG2PDFSettingData.getLayout_scope instead. Setting DWG2PDFSettingData.getLayout_scope to com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeCurrentLayout provides the same behavior as setting current property to true.
Parameters
[in]valuetrue means to export the active layout only, while false means not. Default value: false.
Returns
None.

◆ setIs_output_progress()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setIs_output_progress ( boolean  value)

Set a boolean value which indicates whether to output progress logs.

Parameters
[in]valueA boolean value which indicates whether to output progress logs. true means to output progress logs, and false means not. Default value: true.
Returns
None.

◆ setLayout_index()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setLayout_index ( int  value)

Set layout index used when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeLayoutByIndex .

The Default value is 1 (the first layout). Values less than 1 are normalized to 1 when using layout by index mode. This option is ignored for other layout scope modes.

Parameters
[in]valueLayout index used when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeLayoutByIndex .
Returns
None.

◆ setLayout_scope()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setLayout_scope ( int  value)

Set layout export scope.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeCurrentLayout as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeModelSpaceOnly . When set to com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeLayoutByIndex , use DWG2PDFSettingData.getLayout_index to specify the target layout index. If an unsupported value is provided, it is normalized to com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeCurrentLayout mode.

Parameters
[in]valueLayout export scope.
Returns
None.

◆ setLineweight_scale_factor()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setLineweight_scale_factor ( double  value)

Set lineweight scale factor.

Default value: 1.0. This option is effective only when DWG2PDFSettingData.getLineweight_style_mode is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLineweightStyleModeStyleAndLineweight . Values less than or equal to 0 are treated as 1.0.

Parameters
[in]valueLineweight scale factor.
Returns
None.

◆ setLineweight_style_mode()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setLineweight_style_mode ( int  value)

Set plot lineweight style mode.

It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLineweightStyleModeNoStyleNoLineweight as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLineweightStyleModeNoStyleNoLineweight . If an unsupported value is provided, an com.foxit.sdk.common.Constants.e_ErrParam error will be thrown.

Parameters
[in]valuePlot lineweight style mode.
Returns
None.

◆ setMaximum_drawing_area()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setMaximum_drawing_area ( double  value)

Set maximum allowed drawing frame area (unit is millimeters).

Default value is 0. This option is effective only when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects or com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRectsAndAllLayouts . If a drawing frame's area exceeds this value, it will be scaled down to fit within the limit. A value of 0 means no limit. Negative values will be treated as 0.

Parameters
[in]valueMaximum allowed drawing frame area (unit is millimeters).
Returns
None.

◆ setMinimum_export_rect_side_length()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setMinimum_export_rect_side_length ( double  value)

Set minimum drawing frame side length used by auto-rectangle export (unit is millimeters).

Default value is 0. This option is effective only when DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects . In this mode, any drawing frame whose width or height is smaller than this value will be skipped. If this value exceeds the maximum side length of all detected drawing frames, all frames will be skipped. A value of 0 means no limit. Negative values will be treated as 0.

Parameters
[in]valueMinimum drawing frame side length used by auto-rectangle export (unit is millimeters).
Returns
None.

◆ setMonochrome_image_output_dpi()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setMonochrome_image_output_dpi ( int  value)

Set monochrome image output DPI setting.

Default value: 400. Valid values are 72, 150, 200, 300, 400, 600 and 1200. Values outside this set are normalized to 400.

Parameters
[in]valueMonochrome image output DPI setting.
Returns
None.

◆ setOther_export_hatches_type()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setOther_export_hatches_type ( int  value)

Set the type of other (non-solid) hatches export.

For this option, only com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeDrawing are supported. It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFExportHatchesTypeBitmap and this should be one of these values

Parameters
[in]valueThe type of other (non-solid) hatches export.
Returns
None.

◆ setOutput_author()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setOutput_author ( String  value)

Set the author for the output PDF document, an empty string will be used as default.

Parameters
[in]valueThe author for the output PDF document, an empty string will be used as default.
Returns
None.

◆ setOutput_creator()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setOutput_creator ( String  value)

Set the creator for the output PDF document, an empty string will be used as default.

Parameters
[in]valueThe creator for the output PDF document, an empty string will be used as default.
Returns
None.

◆ setOutput_keywords()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setOutput_keywords ( String  value)

Set the keywords for the output PDF document, an empty string will be used as default.

Parameters
[in]valueThe keywords for the output PDF document, an empty string will be used as default.
Returns
None.

◆ setOutput_producer()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setOutput_producer ( String  value)

Set the producer for the output PDF document, an empty string will be used as default.

Parameters
[in]valueThe producer for the output PDF document, an empty string will be used as default.
Returns
None.

◆ setOutput_subject()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setOutput_subject ( String  value)

Set the subject for the output PDF document, an empty string will be used as default.

Parameters
[in]valueThe subject for the output PDF document, an empty string will be used as default.
Returns
None.

◆ setOutput_title()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setOutput_title ( String  value)

Set the title for the output PDF document, an empty string will be used as default.

Parameters
[in]valueThe title for the output PDF document, an empty string will be used as default.
Returns
None.

◆ setPage_margin()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setPage_margin ( int  value)

Set page margin (unit is millimeters).

Default value: 0. Negative values are treated as 0. Values exceeding half of the page size will be set to less than half of the page size.

Parameters
[in]valuePage margin (unit is millimeters).
Returns
None.

◆ setPaper_height()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setPaper_height ( float  value)

Set the paper height used for the converted PDF document.

This option can be used if layout geometry will be zoomed to paper size(com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagZoomToExtentsMode are enabled by export_flags). Effective default value is 297.0f. Unit: millimeters. If this value is less than or equal to 0, it is normalized to 297.0f.

Parameters
[in]valueThe paper height used for the converted PDF document.
Returns
None.

◆ setPaper_width()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setPaper_width ( float  value)

Set the paper width used for the converted PDF document.

This option can be used if layout geometry will be zoomed to paper size(com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagZoomToExtentsMode are enabled by export_flags). Effective default value is 420.0f. Unit: millimeters. If this value is less than or equal to 0, it is normalized to 420.0f.

Parameters
[in]valueThe paper width used for the converted PDF document.
Returns
None.

◆ setPlot_scale_factor()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setPlot_scale_factor ( double  value)

Set plot scale factor.

Default value is 0.99. No strict upper bound is enforced for this value. However, invalid inputs are normalized to maintain stable output. Values less than 0 are normalized to 0.1, and 0 is normalized to 0.99.

Parameters
[in]valuePlot scale factor.
Returns
None.

◆ setProgress_callback()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setProgress_callback ( java.lang.Object  value)

Set a pointer to a DWG2PDFProgressCallback object which is used to receive the progress of converting DWG to PDF.

Parameters
[in]valueA pointer to a DWG2PDFProgressCallback object which is used to receive the progress of converting DWG to PDF. This parameter can be null.
Returns
None.

◆ setSearchable_text_type()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setSearchable_text_type ( int  value)

Set the type of search text type.

This option can be used if SHX or TTF text exported as geometry(com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagTTFTextAsGeometry and com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagSHXTextAsGeometry are enabled by export_flags). It use com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFSearchableTextTypeNoSearch as the default value of this option. Please refer to values starting from com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFSearchableTextTypeNoSearch and this should be one of these values.

Parameters
[in]valueThe type of search text type.
Returns
None.

◆ setTreat_inches_as_millimeters()

com.foxit.sdk.addon.conversion.DWG2PDFSettingData.setTreat_inches_as_millimeters ( boolean  value)

Set whether to treat inch-based dimensions as millimeters.

Default value is false. This option is effective only when the drawing uses inches as its unit and DWG2PDFSettingData.getLayout_scope is com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeAutoRects . false means disabled, and true means enabled.

Parameters
[in]valueWhether to treat inch-based dimensions as millimeters.
Returns
None.

Member Data Documentation

◆ e_DWG2PDFLayoutScopeFrameBlocks

final int com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_DWG2PDFLayoutScopeFrameBlocks = 4
static

Export configured frame blocks in model space as multiple PDF pages.

Note
Set DWG2PDFSettingData.getFrame_block_configuration_path to an XML configuration file path. Export order is from top-left to bottom-right. If frame blocks are exploded or no block names are configured, the whole model space is exported.

◆ e_FlagZoomToExtentsMode

final int com.foxit.sdk.addon.conversion.DWG2PDFSettingData.e_FlagZoomToExtentsMode = 0x0800
static

Bit 12. If enabled, layout geometry will be zoomed to paper size, else layout settings will be applied.

Note
This mode works like some Layout settings: "Plot Area" - "Extents", "Fit to Paper", "Center the plot", these settings applied to specified paper size and orientation, but some settings like "Plot lineweight", "Plot style" are still applying from Layout settings.