Package com.datalogics.PDFL
Class ExtendedGraphicState
java.lang.Object
com.datalogics.PDFL.ExtendedGraphicState
The extended graphic state, to supplement original graphic state. The Graphics State is an internal data structure in a PDF file that holds the parameters that describe graphics within that file. These parameters define how individual graphics are presented on the page, including layers and transparencies.
The Extended Graphic State was introduced to expand the original Graphics State data structure, providing space to define and store more data objects within a PDF.
-
Constructor Summary
ConstructorsConstructorDescriptionCreate a new default ExtendedGraphicState for the document in which this ExtendedGraphicState will be used. -
Method Summary
Modifier and TypeMethodDescriptionvoiddelete()booleanReturns if the alpha is to be interpreted as a shape or opacity mask.booleanReturns whether stroke adjustment is enabled in the graphics state.booleanSpecifies if overprint is enabled for operations other than stroking.booleanSpecifies if overprint is enabled for stroke operations.Gets the black generation function.Returns the blend mode for the color composite for each object painted.doubleGets the opacity value for other-than-stroke operations.doubleGets the opacity value for stroke operations.Specifies the overprint mode - specifying whether a color component value of 0 in a DeviceCMYK color space should erase that component or leave it unchanged when overprinting.Get the dictionary associated with the extended graphic state.doubleGets the smoothness tolerance, the quality of smooth shading.booleanReturns whether text knockout is enabled in the graphics state.Gets the transfer function.Gets the undercolor removal function.voidsetAlphaIsShape(boolean alphaIsShape) Specifies if the alpha is to be interpreted as a shape or opacity mask.voidsetApplyAutoStroke(boolean applyAutoStrokeAdjustment) Specifies whether stroke adjustment is enabled in the graphics state.voidsetApplyOverprintForOtherThanStroking(boolean applyOverprintForOtherThanStroking) Specifies if overprint is enabled for operations other than stroking.voidsetApplyOverprintForStroking(boolean applyOverprintForStroking) Specifies if overprint is enabled for stroke operations.voidsetBlackGeneration(Function function) Sets the black generation function.voidsetBlendMode(BlendMode blendMode) Sets the blend mode for the color composites for each object painted.voidsetOpacityForOtherThanStroking(double opacity) Sets the opacity value for other-than-stroke operations.voidsetOpacityForStroking(double opacity) Sets the opacity value for stroke operations.voidsetOverprintMode(OverprintMode overprintMode) Specifies the overprint mode - specifying whether a color component value of 0 in a DeviceCMYK color space should erase that component or leave it unchanged when overprinting.voidsetSmoothnessTolerance(double tolerance) Sets the smoothness tolerance, the quality of smooth shading.voidsetTextKnockout(boolean enabled) Specifies whether text knockout is enabled in the graphics state.voidsetTransferFunction(List<Function> function) Sets the transfer function.voidsetUndercolorRemoval(Function function) Sets the undercolor removal function.
-
Constructor Details
-
ExtendedGraphicState
public ExtendedGraphicState()Create a new default ExtendedGraphicState for the document in which this ExtendedGraphicState will be used.
-
-
Method Details
-
delete
public void delete() -
setApplyOverprintForStroking
public void setApplyOverprintForStroking(boolean applyOverprintForStroking) Specifies if overprint is enabled for stroke operations.- Parameters:
applyOverprintForStroking- whether to enable overprint for stroke operations.
-
getApplyOverprintForStroking
public boolean getApplyOverprintForStroking()Specifies if overprint is enabled for stroke operations.- Returns:
- applyOverprintForStroking
-
setApplyOverprintForOtherThanStroking
public void setApplyOverprintForOtherThanStroking(boolean applyOverprintForOtherThanStroking) Specifies if overprint is enabled for operations other than stroking.- Parameters:
applyOverprintForOtherThanStroking- whether to enable overprint for stroke operations.
-
getApplyOverprintForOtherThanStroking
public boolean getApplyOverprintForOtherThanStroking()Specifies if overprint is enabled for operations other than stroking.- Returns:
- applyOverprintForOtherThanStroking
-
setOverprintMode
Specifies the overprint mode - specifying whether a color component value of 0 in a DeviceCMYK color space should erase that component or leave it unchanged when overprinting.- Parameters:
overprintMode- the mode setting.
-
getOverprintMode
Specifies the overprint mode - specifying whether a color component value of 0 in a DeviceCMYK color space should erase that component or leave it unchanged when overprinting.- Returns:
- overprintMode - the mode setting.
-
setApplyAutoStroke
public void setApplyAutoStroke(boolean applyAutoStrokeAdjustment) Specifies whether stroke adjustment is enabled in the graphics state.- Parameters:
applyAutoStrokeAdjustment- whether it is enabled, true or false.
-
getApplyAutoStroke
public boolean getApplyAutoStroke()Returns whether stroke adjustment is enabled in the graphics state.- Returns:
- applyAutoStrokeAdjustment - whether it is enabled, true or false.
-
setBlendMode
Sets the blend mode for the color composites for each object painted.- Parameters:
blendMode- the blend mode used in object painting.
-
getBlendMode
Returns the blend mode for the color composite for each object painted.- Returns:
- blendMode - the blend mode used in object painting.
-
setOpacityForStroking
public void setOpacityForStroking(double opacity) Sets the opacity value for stroke operations.- Parameters:
opacity- the opacity level, from 0.0 to 1.0, inclusive.
-
getOpacityForStroking
public double getOpacityForStroking()Gets the opacity value for stroke operations.- Returns:
- opacity, a value between 0.0 and 1.0.
-
setOpacityForOtherThanStroking
public void setOpacityForOtherThanStroking(double opacity) Sets the opacity value for other-than-stroke operations.- Parameters:
opacity- the opacity level, from 0.0 to 1.0, inclusive.
-
getOpacityForOtherThanStroking
public double getOpacityForOtherThanStroking()Gets the opacity value for other-than-stroke operations.- Returns:
- opacity, a value between 0.0 and 1.0.
-
setAlphaIsShape
public void setAlphaIsShape(boolean alphaIsShape) Specifies if the alpha is to be interpreted as a shape or opacity mask.- Parameters:
alphaIsShape- if set true, interpret sources of alpha as shape, else interpret as opacity mask.
-
getAlphaIsShape
public boolean getAlphaIsShape()Returns if the alpha is to be interpreted as a shape or opacity mask.- Returns:
- alphaIsShape - if set true, interpret sources of alpha as shape, else interpret as opacity mask.
-
setTextKnockout
public void setTextKnockout(boolean enabled) Specifies whether text knockout is enabled in the graphics state.- Parameters:
enabled- if set true, text knockout will be enabled.
-
getTextKnockout
public boolean getTextKnockout()Returns whether text knockout is enabled in the graphics state.- Returns:
- enabled - if true, text knockout is enabled.
-
setSmoothnessTolerance
public void setSmoothnessTolerance(double tolerance) Sets the smoothness tolerance, the quality of smooth shading.- Parameters:
tolerance- the smoothness tolerance, from 0.0 to 1.0, inclusive.
-
getSmoothnessTolerance
public double getSmoothnessTolerance()Gets the smoothness tolerance, the quality of smooth shading.- Returns:
- tolerance, a value between 0.0 and 1.0.
-
setBlackGeneration
Sets the black generation function.- Parameters:
function- the black generation function.
-
getBlackGeneration
Gets the black generation function.- Returns:
- function - the black generation function.
-
setUndercolorRemoval
Sets the undercolor removal function.- Parameters:
function- the undercolor removal function.
-
getUndercolorRemoval
Gets the undercolor removal function.- Returns:
- function - the undercolor removal function.
-
setTransferFunction
Sets the transfer function.- Parameters:
function- the transfer function.
-
getTransferFunction
Gets the transfer function.- Returns:
- function - the transfer function.
-
getPDFDict
Get the dictionary associated with the extended graphic state.- Returns:
- The dictionary associated with the extended graphic state.
-