This class represents the graphics state dictionary that is stored in the PDF document.
The PDGraphicsStateValue holds the current runtime values as a stream is being executed.
RENDERING_INTENT_ABSOLUTE_COLORIMETRIC
public static final String RENDERING_INTENT_ABSOLUTE_COLORIMETRIC
Rendering intent constants, see PDF Reference 1.5 Section 4.5.4 Rendering Intents.
RENDERING_INTENT_PERCEPTUAL
public static final String RENDERING_INTENT_PERCEPTUAL
Rendering intent constants, see PDF Reference 1.5 Section 4.5.4 Rendering Intents.
RENDERING_INTENT_RELATIVE_COLORIMETRIC
public static final String RENDERING_INTENT_RELATIVE_COLORIMETRIC
Rendering intent constants, see PDF Reference 1.5 Section 4.5.4 Rendering Intents.
RENDERING_INTENT_SATURATION
public static final String RENDERING_INTENT_SATURATION
Rendering intent constants, see PDF Reference 1.5 Section 4.5.4 Rendering Intents.
copyIntoGraphicsState
public void copyIntoGraphicsState(PDGraphicsState gs)
throws IOException
This will implement the gs operator.
gs
- The state to copy this dictionaries values into.
getAlphaSourceFlag
public boolean getAlphaSourceFlag()
This will get the alpha source flag.
getAutomaticStrokeAdjustment
public boolean getAutomaticStrokeAdjustment()
This will get the automatic stroke adjustment flag.
- The automatic stroke adjustment flag or null if one has not been set.
getCOSDictionary
public COSDictionary getCOSDictionary()
This will get the underlying dictionary that this class acts on.
- The underlying dictionary for this class.
getCOSObject
public COSBase getCOSObject()
Convert this standard java object to a COS object.
- getCOSObject in interface COSObjectable
- The cos object that matches this Java object.
getFlatnessTolerance
public Float getFlatnessTolerance()
This will get the flatness tolerance.
- The flatness tolerance or null if one has not been set.
getFontSetting
public PDFontSetting getFontSetting()
This will get the font setting of the graphics state.
getLineCapStyle
public int getLineCapStyle()
This will get the line cap style.
- null or the LC value of the dictionary.
getLineDashPattern
public PDLineDashPattern getLineDashPattern()
This will get the dash pattern.
- null or the D value in the dictionary.
getLineJoinStyle
public int getLineJoinStyle()
This will get the line join style.
- null or the LJ value in the dictionary.
getLineWidth
public Float getLineWidth()
This will get the line width. This will return null if there is no line width
- null or the LW value of the dictionary.
getMiterLimit
public Float getMiterLimit()
This will get the miter limit.
- null or the ML value in the dictionary.
getNonStrokingAlpaConstant
public Float getNonStrokingAlpaConstant()
This will get the non stroking alpha constant.
- The non stroking alpha constant or null if one has not been set.
getNonStrokingOverprintControl
public boolean getNonStrokingOverprintControl()
This will get the overprint control for non stroking operations. If this
value is null then the regular overprint control value will be returned.
- The overprint control or null if one has not been set.
getOverprintMode
public Float getOverprintMode()
This will get the overprint control mode.
- The overprint control mode or null if one has not been set.
getRenderingIntent
public String getRenderingIntent()
This will get the rendering intent.
- null or the RI value in the dictionary.
getSmoothnessTolerance
public Float getSmoothnessTolerance()
This will get the smothness tolerance.
- The smothness tolerance or null if one has not been set.
getStrokingAlpaConstant
public Float getStrokingAlpaConstant()
This will get the stroking alpha constant.
- The stroking alpha constant or null if one has not been set.
getStrokingOverprintControl
public boolean getStrokingOverprintControl()
This will get the overprint control.
- The overprint control or null if one has not been set.
getTextKnockoutFlag
public boolean getTextKnockoutFlag()
This will get the text knockout flag.
setAlphaSourceFlag
public void setAlphaSourceFlag(boolean alpha)
This will get the alpha source flag.
alpha
- The alpha source flag.
setAutomaticStrokeAdjustment
public void setAutomaticStrokeAdjustment(boolean sa)
This will get the automatic stroke adjustment flag.
sa
- The new automatic stroke adjustment flag.
setFlatnessTolerance
public void setFlatnessTolerance(Float flatness)
This will get the flatness tolerance.
flatness
- The new flatness tolerance
setFontSetting
public void setFontSetting(PDFontSetting fs)
This will set the font setting for this graphics state.
fs
- The new font setting.
setLineCapStyle
public void setLineCapStyle(int style)
This will set the line cap style for the graphics state.
style
- The new line cap style to set.
setLineDashPattern
public void setLineDashPattern(PDLineDashPattern dashPattern)
This will set the dash pattern for the graphics state.
dashPattern
- The dash pattern
setLineJoinStyle
public void setLineJoinStyle(int style)
This will set the line join style.
style
- The new line join style.
setLineWidth
public void setLineWidth(Float width)
This will set the line width.
width
- The line width for the object.
setMiterLimit
public void setMiterLimit(Float miterLimit)
This will set the miter limit for the graphics state.
miterLimit
- The new miter limit value
setNonStrokingAlphaConstant
public void setNonStrokingAlphaConstant(Float alpha)
This will get the non stroking alpha constant.
alpha
- The new non stroking alpha constant.
setNonStrokingOverprintControl
public void setNonStrokingOverprintControl(boolean op)
This will get the overprint control(OP).
op
- The overprint control.
setOverprintMode
public void setOverprintMode(Float overprintMode)
This will get the overprint mode(OPM).
overprintMode
- The overprint mode
setRenderingIntent
public void setRenderingIntent(String ri)
This will set the rendering intent for the graphics state.
ri
- The new rendering intent
setSmoothnessTolerance
public void setSmoothnessTolerance(Float smoothness)
This will get the smoothness tolerance.
smoothness
- The new smoothness tolerance
setStrokingAlphaConstant
public void setStrokingAlphaConstant(Float alpha)
This will get the stroking alpha constant.
alpha
- The new stroking alpha constant.
setStrokingOverprintControl
public void setStrokingOverprintControl(boolean op)
This will get the overprint control(OP).
op
- The overprint control.
setTextKnockoutFlag
public void setTextKnockoutFlag(boolean tk)
This will get the text knockout flag.
tk
- The text knockout flag.