SvgExtractionOptions

Inheritance: java.lang.Object, com.aspose.pdf.vector.extraction.SvgExtractionOptions

public class SvgExtractionOptions extends Object

Represents an options class for extracting vector graphics from the pdf document page.

Constructors

ConstructorDescription
SvgExtractionOptionsCreates SvgExtractionOptions class instance.

Methods

MethodDescription
getAutoGroupingGets and sets the option to automatically group subpaths into images. This option excludes the {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.GroupStrengthGroupStrength}({@link #getGroupStrength}/{@link #setGroupStrength(double)}) option.
getExtractEverySubPathToSvgGets and sets option to extracts every subpath from a PDF document to separate SVG images.
getExtractionAreaBoundGets and sets the bounding rectangle that defines the extraction area for SVG extraction.
getGroupStrengthGets and sets an option The strength of grouping subpaths into images. Allows you to configure the degree of grouping of subpaths. The value ranges is from 0 to 1. A value of 0 corresponds to the {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractEverySubPathToSvgExtractEverySubPathToSvg}({@link #getExtractEverySubPathToSvg}/{@link #setExtractEverySubPathToSvg(boolean)}) option being enabled. A value of 1 will create single image for all vector paths on the page. The option has an effect when {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.AutoGroupingAutoGrouping}({@link #getAutoGrouping}/{@link #setAutoGrouping(boolean)}) is false. The default value is {@code 0.8}.
getMinStrokeWidthGets or sets the minimum stroke width that will be used in the resulting SVG. If the PDF use a thinner stroke width, it will be replaced with this width. The default value is 0.5. The value is expressed in transformed user space units of the converted PDF page. By default 1 user space unit is 1/72 inch (0.35 mm), but this can be overridden by the PDF document. Transforms can affect the actual minimum width in the generated SVG.
getStrictExtractionAreaBoundCheckGets and sets an option to define strictly checks whether subpaths are within the specified rectangle in {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractionAreaBoundExtractionAreaBound}({@link #getExtractionAreaBound}/{@link #setExtractionAreaBound(Rectangle)}). If set to false, then subpaths that are not completely included in {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractionAreaBoundExtractionAreaBound}({@link #getExtractionAreaBound}/{@link #setExtractionAreaBound(Rectangle)}) will be extracted. The default value is {@code True}.
getUnpackPageContentXFormGets and sets a flag that determines whether XFrom found on pages should be unpacked or not. XFrom elements can end up in different SVG files. Only XForms that are rendered by Do statements from the page content are unpacked. Nested XForms are not unpacked.
getUnpackXFormPredicateGets and sets option to unpack only the XForm corresponding to the specified predicate.
setAutoGroupingGets and sets the option to automatically group subpaths into images. This option excludes the {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.GroupStrengthGroupStrength}({@link #getGroupStrength}/{@link #setGroupStrength(double)}) option.
setExtractEverySubPathToSvgGets and sets option to extracts every subpath from a PDF document to separate SVG images.
setExtractionAreaBoundGets and sets the bounding rectangle that defines the extraction area for SVG extraction.
setGroupStrengthGets and sets an option The strength of grouping subpaths into images. Allows you to configure the degree of grouping of subpaths. The value ranges is from 0 to 1. A value of 0 corresponds to the {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractEverySubPathToSvgExtractEverySubPathToSvg}({@link #getExtractEverySubPathToSvg}/{@link #setExtractEverySubPathToSvg(boolean)}) option being enabled. A value of 1 will create single image for all vector paths on the page. The option has an effect when {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.AutoGroupingAutoGrouping}({@link #getAutoGrouping}/{@link #setAutoGrouping(boolean)}) is false. The default value is {@code 0.8}.
setMinStrokeWidthGets or sets the minimum stroke width that will be used in the resulting SVG. If the PDF use a thinner stroke width, it will be replaced with this width. The default value is 0.5. The value is expressed in transformed user space units of the converted PDF page. By default 1 user space unit is 1/72 inch (0.35 mm), but this can be overridden by the PDF document. Transforms can affect the actual minimum width in the generated SVG.
setStrictExtractionAreaBoundCheckGets and sets an option to define strictly checks whether subpaths are within the specified rectangle in {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractionAreaBoundExtractionAreaBound}({@link #getExtractionAreaBound}/{@link #setExtractionAreaBound(Rectangle)}). If set to false, then subpaths that are not completely included in {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractionAreaBoundExtractionAreaBound}({@link #getExtractionAreaBound}/{@link #setExtractionAreaBound(Rectangle)}) will be extracted. The default value is {@code True}.
setUnpackPageContentXFormGets and sets a flag that determines whether XFrom found on pages should be unpacked or not. XFrom elements can end up in different SVG files. Only XForms that are rendered by Do statements from the page content are unpacked. Nested XForms are not unpacked.
setUnpackXFormPredicateGets and sets option to unpack only the XForm corresponding to the specified predicate.

SvgExtractionOptions

public SvgExtractionOptions()

Creates SvgExtractionOptions class instance.

getAutoGrouping

public final boolean getAutoGrouping()

Gets and sets the option to automatically group subpaths into images. This option excludes the {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.GroupStrengthGroupStrength}({@link #getGroupStrength}/{@link #setGroupStrength(double)}) option.

Returns: boolean value

getExtractEverySubPathToSvg

public final boolean getExtractEverySubPathToSvg()

Gets and sets option to extracts every subpath from a PDF document to separate SVG images.

Returns: boolean value

getExtractionAreaBound

public final Rectangle getExtractionAreaBound()

Gets and sets the bounding rectangle that defines the extraction area for SVG extraction.

Returns: Rectangle instance

getGroupStrength

public final double getGroupStrength()

Gets and sets an option The strength of grouping subpaths into images. Allows you to configure the degree of grouping of subpaths. The value ranges is from 0 to 1. A value of 0 corresponds to the {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractEverySubPathToSvgExtractEverySubPathToSvg}({@link #getExtractEverySubPathToSvg}/{@link #setExtractEverySubPathToSvg(boolean)}) option being enabled. A value of 1 will create single image for all vector paths on the page. The option has an effect when {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.AutoGroupingAutoGrouping}({@link #getAutoGrouping}/{@link #setAutoGrouping(boolean)}) is false. The default value is {@code 0.8}.

Returns: double value

getMinStrokeWidth

public final double getMinStrokeWidth()

Gets or sets the minimum stroke width that will be used in the resulting SVG. If the PDF use a thinner stroke width, it will be replaced with this width. The default value is 0.5. The value is expressed in transformed user space units of the converted PDF page. By default 1 user space unit is 1/72 inch (0.35 mm), but this can be overridden by the PDF document. Transforms can affect the actual minimum width in the generated SVG.

Returns: double value

getStrictExtractionAreaBoundCheck

public final boolean getStrictExtractionAreaBoundCheck()

Gets and sets an option to define strictly checks whether subpaths are within the specified rectangle in {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractionAreaBoundExtractionAreaBound}({@link #getExtractionAreaBound}/{@link #setExtractionAreaBound(Rectangle)}). If set to false, then subpaths that are not completely included in {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractionAreaBoundExtractionAreaBound}({@link #getExtractionAreaBound}/{@link #setExtractionAreaBound(Rectangle)}) will be extracted. The default value is {@code True}.

Returns: boolean value

getUnpackPageContentXForm

public final boolean getUnpackPageContentXForm()

Gets and sets a flag that determines whether XFrom found on pages should be unpacked or not. XFrom elements can end up in different SVG files. Only XForms that are rendered by Do statements from the page content are unpacked. Nested XForms are not unpacked.

Returns: boolean value

getUnpackXFormPredicate

public final com.aspose.ms.System.Predicate< XFormPlacement > getUnpackXFormPredicate()

Gets and sets option to unpack only the XForm corresponding to the specified predicate.

Returns: internal Predicate instance of XFormPlacement instance

setAutoGrouping

public final void setAutoGrouping(boolean value)

Gets and sets the option to automatically group subpaths into images. This option excludes the {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.GroupStrengthGroupStrength}({@link #getGroupStrength}/{@link #setGroupStrength(double)}) option.

Parameters:

ParameterTypeDescription
valueboolean value

setExtractEverySubPathToSvg

public final void setExtractEverySubPathToSvg(boolean value)

Gets and sets option to extracts every subpath from a PDF document to separate SVG images.

Parameters:

ParameterTypeDescription
valueboolean value

setExtractionAreaBound

Gets and sets the bounding rectangle that defines the extraction area for SVG extraction.

setGroupStrength

public final void setGroupStrength(double value)

Gets and sets an option The strength of grouping subpaths into images. Allows you to configure the degree of grouping of subpaths. The value ranges is from 0 to 1. A value of 0 corresponds to the {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractEverySubPathToSvgExtractEverySubPathToSvg}({@link #getExtractEverySubPathToSvg}/{@link #setExtractEverySubPathToSvg(boolean)}) option being enabled. A value of 1 will create single image for all vector paths on the page. The option has an effect when {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.AutoGroupingAutoGrouping}({@link #getAutoGrouping}/{@link #setAutoGrouping(boolean)}) is false. The default value is {@code 0.8}.

Parameters:

ParameterTypeDescription
valuedouble value

setMinStrokeWidth

public final void setMinStrokeWidth(double value)

Gets or sets the minimum stroke width that will be used in the resulting SVG. If the PDF use a thinner stroke width, it will be replaced with this width. The default value is 0.5. The value is expressed in transformed user space units of the converted PDF page. By default 1 user space unit is 1/72 inch (0.35 mm), but this can be overridden by the PDF document. Transforms can affect the actual minimum width in the generated SVG.

Parameters:

ParameterTypeDescription
valuedouble value

setStrictExtractionAreaBoundCheck

public final void setStrictExtractionAreaBoundCheck(boolean value)

Gets and sets an option to define strictly checks whether subpaths are within the specified rectangle in {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractionAreaBoundExtractionAreaBound}({@link #getExtractionAreaBound}/{@link #setExtractionAreaBound(Rectangle)}). If set to false, then subpaths that are not completely included in {@code Aspose.Pdf.Vector.Extraction.SvgExtractionOptions.ExtractionAreaBoundExtractionAreaBound}({@link #getExtractionAreaBound}/{@link #setExtractionAreaBound(Rectangle)}) will be extracted. The default value is {@code True}.

Parameters:

ParameterTypeDescription
valueboolean value

setUnpackPageContentXForm

public final void setUnpackPageContentXForm(boolean value)

Gets and sets a flag that determines whether XFrom found on pages should be unpacked or not. XFrom elements can end up in different SVG files. Only XForms that are rendered by Do statements from the page content are unpacked. Nested XForms are not unpacked.

Parameters:

ParameterTypeDescription
valueboolean value

setUnpackXFormPredicate

Gets and sets option to unpack only the XForm corresponding to the specified predicate.