Class PDGraphicsState
java.lang.Object
org.apache.pdfbox.pdmodel.graphics.PDGraphicsState
- All Implemented Interfaces:
Cloneable
This class will hold the current state of the graphics parameters when executing a
content stream.
- Version:
- $Revision: 1.5 $
- Author:
- Ben Litchfield
-
Constructor Summary
ConstructorsConstructorDescriptionDefault constructor.PDGraphicsState(PDRectangle page) Constructor with a given pagesize to initialize the clipping path. -
Method Summary
Modifier and TypeMethodDescriptionclone()doubleGet the value of the stroke alpha constants property.This will get the current clipping path.Get the value of the CTM.doubleget the value of the flatness property.intGet the value of the line cap.This will get the current line dash pattern.intGet the value of the line join.doubleGet the value of the line width.doubleGet the value of the miter limit.doubleGet the value of the non-stroke alpha constants property.Returns the non-stroking color state.doubleget the value of the overprint mode property.This will get the rendering intent.doubleget the value of the smoothness property.Returns the stroking color state.This will get the graphics text state.booleanget the value of the stroke alpha source property.booleanget the value of the overprint property.booleanGet the value of the stroke adjustment parameter.voidsetAlphaConstants(double value) set the value of the stroke alpha constants property.voidsetAlphaSource(boolean value) set the value of the alpha source property.voidsetCurrentClippingPath(Shape pCurrentClippingPath) This will set the current clipping path.voidSet the value of the CTM.voidsetFlatness(double value) set the value of the flatness property.voidsetLineCap(int value) set the value of the line cap.voidThis will set the current line dash pattern.voidsetLineJoin(int value) Get the value of the line join.voidsetLineWidth(double value) set the value of the line width.voidsetMiterLimit(double value) set the value of the miter limit.voidsetNonStrokeAlphaConstants(double value) set the value of the non-stroke alpha constants property.voidsetOverprint(boolean value) set the value of the overprint property.voidsetOverprintMode(double value) set the value of the overprint mode property.voidsetRenderingIntent(String value) This will set the rendering intent.voidsetSmoothness(double value) set the value of the smoothness property.voidsetStrokeAdjustment(boolean value) set the value of the stroke adjustment.voidsetTextState(PDTextState value) This will set the graphics text state.
-
Constructor Details
-
PDGraphicsState
public PDGraphicsState()Default constructor. -
PDGraphicsState
Constructor with a given pagesize to initialize the clipping path.- Parameters:
page- the size of the page
-
-
Method Details
-
getCurrentTransformationMatrix
Get the value of the CTM.- Returns:
- The current transformation matrix.
-
setCurrentTransformationMatrix
Set the value of the CTM.- Parameters:
value- The current transformation matrix.
-
getLineWidth
public double getLineWidth()Get the value of the line width.- Returns:
- The current line width.
-
setLineWidth
public void setLineWidth(double value) set the value of the line width.- Parameters:
value- The current line width.
-
getLineCap
public int getLineCap()Get the value of the line cap.- Returns:
- The current line cap.
-
setLineCap
public void setLineCap(int value) set the value of the line cap.- Parameters:
value- The current line cap.
-
getLineJoin
public int getLineJoin()Get the value of the line join.- Returns:
- The current line join value.
-
setLineJoin
public void setLineJoin(int value) Get the value of the line join.- Parameters:
value- The current line join
-
getMiterLimit
public double getMiterLimit()Get the value of the miter limit.- Returns:
- The current miter limit.
-
setMiterLimit
public void setMiterLimit(double value) set the value of the miter limit.- Parameters:
value- The current miter limit.
-
isStrokeAdjustment
public boolean isStrokeAdjustment()Get the value of the stroke adjustment parameter.- Returns:
- The current stroke adjustment.
-
setStrokeAdjustment
public void setStrokeAdjustment(boolean value) set the value of the stroke adjustment.- Parameters:
value- The value of the stroke adjustment parameter.
-
getAlphaConstants
public double getAlphaConstants()Get the value of the stroke alpha constants property.- Returns:
- The value of the stroke alpha constants parameter.
-
setAlphaConstants
public void setAlphaConstants(double value) set the value of the stroke alpha constants property.- Parameters:
value- The value of the stroke alpha constants parameter.
-
getNonStrokeAlphaConstants
public double getNonStrokeAlphaConstants()Get the value of the non-stroke alpha constants property.- Returns:
- The value of the non-stroke alpha constants parameter.
-
setNonStrokeAlphaConstants
public void setNonStrokeAlphaConstants(double value) set the value of the non-stroke alpha constants property.- Parameters:
value- The value of the non-stroke alpha constants parameter.
-
isAlphaSource
public boolean isAlphaSource()get the value of the stroke alpha source property.- Returns:
- The value of the stroke alpha source parameter.
-
setAlphaSource
public void setAlphaSource(boolean value) set the value of the alpha source property.- Parameters:
value- The value of the alpha source parameter.
-
isOverprint
public boolean isOverprint()get the value of the overprint property.- Returns:
- The value of the overprint parameter.
-
setOverprint
public void setOverprint(boolean value) set the value of the overprint property.- Parameters:
value- The value of the overprint parameter.
-
getOverprintMode
public double getOverprintMode()get the value of the overprint mode property.- Returns:
- The value of the overprint mode parameter.
-
setOverprintMode
public void setOverprintMode(double value) set the value of the overprint mode property.- Parameters:
value- The value of the overprint mode parameter.
-
getFlatness
public double getFlatness()get the value of the flatness property.- Returns:
- The value of the flatness parameter.
-
setFlatness
public void setFlatness(double value) set the value of the flatness property.- Parameters:
value- The value of the flatness parameter.
-
getSmoothness
public double getSmoothness()get the value of the smoothness property.- Returns:
- The value of the smoothness parameter.
-
setSmoothness
public void setSmoothness(double value) set the value of the smoothness property.- Parameters:
value- The value of the smoothness parameter.
-
getTextState
This will get the graphics text state.- Returns:
- The graphics text state.
-
setTextState
This will set the graphics text state.- Parameters:
value- The graphics text state.
-
getLineDashPattern
This will get the current line dash pattern.- Returns:
- The line dash pattern.
-
setLineDashPattern
This will set the current line dash pattern.- Parameters:
value- The new line dash pattern.
-
getRenderingIntent
This will get the rendering intent.- Returns:
- The rendering intent
- See Also:
-
setRenderingIntent
This will set the rendering intent.- Parameters:
value- The new rendering intent.
-
clone
-
getStrokingColor
Returns the stroking color state.- Returns:
- stroking color state
-
getNonStrokingColor
Returns the non-stroking color state.- Returns:
- non-stroking color state
-
setCurrentClippingPath
This will set the current clipping path.- Parameters:
pCurrentClippingPath- The current clipping path.
-
getCurrentClippingPath
This will get the current clipping path.- Returns:
- The current clipping path.
-
getStrokeJavaComposite
-
getNonStrokeJavaComposite
-