Package com.datalogics.PDFL
Class GraphicState
java.lang.Object
com.datalogics.PDFL.GraphicState
The graphic state is an internal data structure in a PDF file. The graphics state holds the parameters that describe graphics within that file.
These parameters define how individual graphics are presented on the page, including layers and transparencies.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoiddelete()The line DashPattern controls the pattern of dashes and gaps used to stroke paths.The ExtendedGraphicState, which can contain additional graphic state parameters.The fill color of the GraphicState.The line cap used by the current GraphicState.doubleThe line flatness corresponding to the i operator. Default is 1.0.The line join style used by the current GraphicState.doubleThe miter limit corresponding to the M operator. Default is 10.0.A color rendering intent corresponding to the Intent key in the image dictionary.The stroke color of the GraphicState.doublegetWidth()The width used for drawing by the current GraphicState.voidsetDashPattern(List<Double> DashPattern) The line DashPattern controls the pattern of dashes and gaps used to stroke paths.voidsetExtendedGraphicState(ExtendedGraphicState extendedGraphicState) The ExtendedGraphicState, which can contain additional graphic state parameters.voidsetFillColor(Color fillcolor) The fill color of the GraphicState.voidsetLineCap(LineCap LineCap) The line cap used by the current GraphicState.voidsetLineFlatness(double flatness) The line flatness corresponding to the i operator. Default is 1.0.voidsetLineJoin(LineJoin LineJoin) The line join style to be used by the current GraphicState.voidsetMiterLimit(double miterLimit) The miter limit corresponding to the M operator. Default is 10.0.voidsetRenderIntent(RenderIntent renderingIntent) A color rendering intent corresponding to the Intent key in the image dictionary.voidsetStrokeColor(Color strokecolor) The stroke color of the GraphicState.voidsetWidth(double width) The width used for drawing by the current GraphicState.
-
Constructor Details
-
GraphicState
public GraphicState()Create a new default GraphicState.
-
-
Method Details
-
delete
public void delete() -
getWidth
public double getWidth()The width used for drawing by the current GraphicState. -
setWidth
public void setWidth(double width) The width used for drawing by the current GraphicState. -
getLineCap
The line cap used by the current GraphicState. -
setLineCap
The line cap used by the current GraphicState. -
getLineJoin
The line join style used by the current GraphicState. -
setLineJoin
The line join style to be used by the current GraphicState. -
getDashPattern
The line DashPattern controls the pattern of dashes and gaps used to stroke paths. It is specified by a dash phase and then a series of elements of a DashPattern list. The DashPattern's members are numbers that specify the lengths of alternating dashes and gaps; the numbers must be nonnegative and not all zero. The dash phase specifies the distance into the dash pattern at which to start the dash. The elements of both the DashPattern List and the dash phase are expressed in user space units. This retrieves the DashPattern used by the Pattern list current graphic state.- Returns:
- A list containing the dash phase followed by the contents of the DashPattern.
-
setDashPattern
The line DashPattern controls the pattern of dashes and gaps used to stroke paths. It is specified by a dash phase and then a series of elements of a DashPattern list. The DashPattern's members are numbers that specify the lengths of alternating dashes and gaps; the numbers must be nonnegative and not all zero. The dash phase specifies the distance into the dash pattern at which to start the dash. The elements of both the DashPattern List and the dash phase are expressed in user space units. This retrieves the DashPattern used by the Pattern list current graphic state.- Parameters:
DashPattern- A list containing the dash phase followed by the contents of the DashPattern.
-
setFillColor
The fill color of the GraphicState.- Parameters:
fillcolor- (DeviceGray, GrayScalevalue or fillcolor (DeviceRGB, Redvalue, Greenvalue, Bluevalue or fillcolor (DeviceCMYK, Cyanvalue, Magentavalue, Yellowvalue, Blackvalue
-
setStrokeColor
The stroke color of the GraphicState.- Parameters:
strokecolor- (DeviceGray, GrayScalevalue or strokecolor (DeviceRGB, Redvalue, Greenvalue, Bluevalue or strokecolor (DeviceCMYK, Cyanvalue, Magentavalue, Yellowvalue, Blackvalue
-
getFillColor
The fill color of the GraphicState. -
getStrokeColor
The stroke color of the GraphicState. -
getMiterLimit
public double getMiterLimit()The miter limit corresponding to the M operator. Default is 10.0. -
setMiterLimit
public void setMiterLimit(double miterLimit) The miter limit corresponding to the M operator. Default is 10.0. -
getLineFlatness
public double getLineFlatness()The line flatness corresponding to the i operator. Default is 1.0. -
setLineFlatness
public void setLineFlatness(double flatness) The line flatness corresponding to the i operator. Default is 1.0. -
getRenderIntent
A color rendering intent corresponding to the Intent key in the image dictionary. The default is RelColorimetric. -
setRenderIntent
A color rendering intent corresponding to the Intent key in the image dictionary. The default is RelColorimetric. -
getExtendedGraphicState
The ExtendedGraphicState, which can contain additional graphic state parameters. -
setExtendedGraphicState
The ExtendedGraphicState, which can contain additional graphic state parameters.
-