public class PdfExtGState extends PdfObjectWrapper<PdfDictionary>
Modifier and Type | Field and Description |
---|---|
static PdfName |
BM_COLOR
Standard nonseparable blend mode.
|
static PdfName |
BM_COLOR_BURN
Standard separable blend mode.
|
static PdfName |
BM_COLOR_DODGE
Standard separable blend mode.
|
static PdfName |
BM_DARKEN
Standard separable blend mode.
|
static PdfName |
BM_DIFFERENCE
Standard separable blend mode.
|
static PdfName |
BM_EXCLUSION
Standard separable blend mode.
|
static PdfName |
BM_HARD_LIGHT
Standard separable blend mode.
|
static PdfName |
BM_HUE
Standard nonseparable blend mode.
|
static PdfName |
BM_LIGHTEN
Standard separable blend mode.
|
static PdfName |
BM_LUMINOSITY
Standard nonseparable blend mode.
|
static PdfName |
BM_MULTIPLY
Standard separable blend mode.
|
static PdfName |
BM_NORMAL
Standard separable blend mode.
|
static PdfName |
BM_OVERLAY
Standard separable blend mode.
|
static PdfName |
BM_SATURATION
Standard nonseparable blend mode.
|
static PdfName |
BM_SCREEN
Standard separable blend mode.
|
static PdfName |
BM_SOFT_LIGHT
Standard separable blend mode.
|
Constructor and Description |
---|
PdfExtGState()
Create default instance of graphics state parameter dictionary
|
PdfExtGState(PdfDictionary pdfObject)
Create instance of graphics state parameter dictionary wrapper by existed PdfDictionary object
|
Modifier and Type | Method and Description |
---|---|
void |
flush()
To manually flush a PdfObject behind this wrapper, you have to ensure that this object is added to the document, i.e.
|
Boolean |
getAlphaSourceFlag()
Gets the alpha source flag (“alpha is shape”), specifying whether the current soft mask and alpha constant shall be interpreted as shape values ( true ) or opacity values (false ), AIS key.
|
Boolean |
getAutomaticStrokeAdjustmentFlag()
Gets value of an automatic stroke adjustment flag, SA key.
|
PdfObject |
getBlackGenerationFunction()
Gets the black-generation function value, BG .
|
PdfObject |
getBlackGenerationFunction2()
Gets the black-generation function value or Default , BG2 key.
|
PdfObject |
getBlendMode()
Gets the current blend mode for the transparent imaging model, BM key.
|
PdfArray |
getDashPattern()
Gets line dash pattern value, D key.
|
Float |
getFillOpacity()
Gets the current alpha constant, specifying the constant shape or constant opacity value for non-stroking operations in the transparent imaging model, ca key.
|
Boolean |
getFillOverprintFlag()
Get overprint flag value for non-stroking operations, op key.
|
Float |
getFlatnessTolerance()
Gets the flatness tolerance value, FL key.
|
PdfArray |
getFont()
Gets font and size, Font key.
|
PdfObject |
getHalftone()
Gets the halftone dictionary, stream or Default , HT key.
|
PdfObject |
getHTP()
Deprecated.
|
Integer |
getLineCapStyle()
Gets line gap style value, LC key.
|
Integer |
getLineJoinStyle()
Gets line join style value, LJ key.
|
Float |
getLineWidth()
Gets line width value, LW key.
|
Float |
getMiterLimit()
Gets miter limit value, ML key .
|
Integer |
getOverprintMode()
Get overprint control mode, OPM key.
|
PdfName |
getRenderingIntent()
Gets rendering intent value, RI key.
|
Float |
getSmothnessTolerance()
Gets the smoothness tolerance value, SM key.
|
PdfObject |
getSoftMask()
Gets the current soft mask, SMask key.
|
Float |
getStrokeOpacity()
Gets the current alpha constant, specifying the constant shape or constant opacity value for stroking operations in the transparent imaging model, CA key.
|
Boolean |
getStrokeOverprintFlag()
Get overprint flag value for stroking operations, OP key.
|
Boolean |
getTextKnockoutFlag()
Gets the text knockout flag, which determine the behaviour of overlapping glyphs within a text object in the transparent imaging model, TK key.
|
PdfObject |
getTransferFunction()
Gets the transfer function value, TR key.
|
PdfObject |
getTransferFunction2()
Gets the transfer function value or Default , TR2 key.
|
PdfObject |
getUndercolorRemovalFunction()
Gets the undercolor-removal function, UCR key.
|
PdfObject |
getUndercolorRemovalFunction2()
Gets the undercolor-removal function value or Default , UCR2 key.
|
protected boolean |
isWrappedObjectMustBeIndirect()
Defines if the object behind this wrapper must be an indirect object in the resultant document.
|
PdfExtGState |
put(PdfName key, PdfObject value)
Puts the value into Graphics state parameter dictionary and associates it with the specified key.
|
PdfExtGState |
setAlphaSourceFlag(boolean alphaSourceFlag)
Sets the alpha source flag (“alpha is shape”), specifying whether the current soft mask and alpha constant shall be interpreted as shape values ( true ) or opacity values (false ), AIS key.
|
PdfExtGState |
setAutomaticStrokeAdjustmentFlag(boolean strokeAdjustment)
Sets value of an automatic stroke adjustment flag, SA key.
|
PdfExtGState |
setBlackGenerationFunction(PdfObject blackGenerationFunction)
Sets the black-generation function value, BG .
|
PdfExtGState |
setBlackGenerationFunction2(PdfObject blackGenerationFunction2)
Sets the black-generation function value or Default , BG2 key.
|
PdfExtGState |
setBlendMode(PdfObject blendMode)
Sets the current blend mode for the transparent imaging model, BM key.
|
PdfExtGState |
setDashPattern(PdfArray dashPattern)
Sets line dash pattern value, D key.
|
PdfExtGState |
setFillOpacity(float fillingAlphaConstant)
Sets the current alpha constant, specifying the constant shape or constant opacity value for non-stroking operations in the transparent imaging model, ca key.
|
PdfExtGState |
setFillOverPrintFlag(boolean fillOverprintFlag)
Set overprint flag value for non-stroking operations, op key.
|
PdfExtGState |
setFlatnessTolerance(float flatnessTolerance)
Sets the flatness tolerance value, FL key.
|
PdfExtGState |
setFont(PdfArray font)
Sets font and size, Font key.
|
PdfExtGState |
setHalftone(PdfObject halftone)
Sets the halftone or Default , HT key.
|
PdfExtGState |
setHTP(PdfObject htp)
Deprecated.
|
PdfExtGState |
setLineCapStryle(int lineCapStyle)
Deprecated.
Use
setLineCapStyle(int) instead.
|
PdfExtGState |
setLineCapStyle(int lineCapStyle)
Sets line gap style value, LC key.
|
PdfExtGState |
setLineJoinStyle(int lineJoinStyle)
Sets line join style value, LJ key.
|
PdfExtGState |
setLineWidth(float lineWidth)
Sets line width value, LW key.
|
PdfExtGState |
setMiterLimit(float miterLimit)
Sets miter limit value, ML key .
|
PdfExtGState |
setOverprintMode(int overprintMode)
Set overprint control mode, OPM key.
|
PdfExtGState |
setRenderingIntent(PdfName renderingIntent)
Sets rendering intent value, RI key.
|
PdfExtGState |
setSmoothnessTolerance(float smoothnessTolerance)
Sets the smoothness tolerance value, SM key.
|
PdfExtGState |
setSoftMask(PdfObject sMask)
Sets the current soft mask, SMask key.
|
PdfExtGState |
setStrokeOpacity(float strokingAlphaConstant)
Sets the current alpha constant, specifying the constant shape or constant opacity value for stroking operations in the transparent imaging model, CA key.
|
PdfExtGState |
setStrokeOverPrintFlag(boolean strokeOverPrintFlag)
Set overprint flag value for stroking operations, OP key.
|
PdfExtGState |
setTextKnockoutFlag(boolean textKnockoutFlag)
Sets the text knockout flag, which determine the behaviour of overlapping glyphs within a text object in the transparent imaging model, TK key.
|
PdfExtGState |
setTransferFunction(PdfObject transferFunction)
Sets the transfer function value, TR key.
|
PdfExtGState |
setTransferFunction2(PdfObject transferFunction2)
Sets the transfer function value or Default , TR2 key.
|
PdfExtGState |
setUndercolorRemovalFunction(PdfObject undercolorRemovalFunction)
Sets the undercolor-removal function, UCR key.
|
PdfExtGState |
setUndercolorRemovalFunction2(PdfObject undercolorRemovalFunction2)
Sets the undercolor-removal function value or Default , UCR2 key.
|
ensureObjectIsAddedToDocument, getPdfObject, isFlushed, makeIndirect, makeIndirect, markObjectAsIndirect, setForbidRelease, setModified, setPdfObject, unsetForbidRelease
public static PdfName BM_NORMAL
public static PdfName BM_MULTIPLY
public static PdfName BM_SCREEN
public static PdfName BM_OVERLAY
public static PdfName BM_DARKEN
public static PdfName BM_LIGHTEN
public static PdfName BM_COLOR_DODGE
public static PdfName BM_COLOR_BURN
public static PdfName BM_HARD_LIGHT
public static PdfName BM_SOFT_LIGHT
public static PdfName BM_DIFFERENCE
public static PdfName BM_EXCLUSION
public static PdfName BM_HUE
public static PdfName BM_SATURATION
public static PdfName BM_COLOR
public static PdfName BM_LUMINOSITY
public PdfExtGState(PdfDictionary pdfObject)
PdfDictionary
object
pdfObject
- instance of graphics state parameter dictionary
public PdfExtGState()
public Float getLineWidth()
LW
key.
float
value if exist, otherwise null
.
public PdfExtGState setLineWidth(float lineWidth)
LW
key.
lineWidth
- a float
value.
public Integer getLineCapStyle()
LC
key.
@Deprecated public PdfExtGState setLineCapStryle(int lineCapStyle)
setLineCapStyle(int)
instead.
LC
key.
lineCapStyle
- 0 - butt cap, 1 - round cap, 2 - projecting square cap.
public PdfExtGState setLineCapStyle(int lineCapStyle)
LC
key.
lineCapStyle
- 0 - butt cap, 1 - round cap, 2 - projecting square cap.
public Integer getLineJoinStyle()
LJ
key.
public PdfExtGState setLineJoinStyle(int lineJoinStyle)
LJ
key.
lineJoinStyle
- 0 - miter join (see also miter limit), 1 - round join, 2 - bevel join.
public Float getMiterLimit()
ML key
. See also line join style.
float
value if exist, otherwise null
.
public PdfExtGState setMiterLimit(float miterLimit)
ML key
. See also line join style.
miterLimit
- a float
value.
public PdfArray getDashPattern()
D
key.
PdfArray
, that represents line dash pattern.
public PdfExtGState setDashPattern(PdfArray dashPattern)
D
key.
dashPattern
- a PdfArray
, that represents line dash pattern.
public PdfName getRenderingIntent()
RI
key. Valid values are: AbsoluteColorimetric
, RelativeColorimetric
, Saturation
, Perceptual
.
PdfName
instance.
public PdfExtGState setRenderingIntent(PdfName renderingIntent)
RI
key.
renderingIntent
- a PdfName
instance, Valid values are: AbsoluteColorimetric
, RelativeColorimetric
, Saturation
, Perceptual
.
public Boolean getStrokeOverprintFlag()
OP
key.
boolean
value if exist, otherwise null
.
public PdfExtGState setStrokeOverPrintFlag(boolean strokeOverPrintFlag)
OP
key.
strokeOverPrintFlag
- true
, for applying overprint for stroking operations.
public Boolean getFillOverprintFlag()
op
key.
boolean
value if exist, otherwise null
.
public PdfExtGState setFillOverPrintFlag(boolean fillOverprintFlag)
op
key.
fillOverprintFlag
- true
, for applying overprint for non-stroking operations.
public Integer getOverprintMode()
OPM
key.
int
value if exist, otherwise null
.
public PdfExtGState setOverprintMode(int overprintMode)
OPM
key.
overprintMode
- an int
value, see ISO-320001, 8.6.7 Overprint Control.
public PdfArray getFont()
Font
key.
PdfArray
of the form [font size]
, where font
shall be an indirect reference to a font dictionary and size
shall be a number expressed in text space units.
public PdfExtGState setFont(PdfArray font)
Font
key.
font
- a PdfArray
of the form [font size]
, where font
shall be an indirect reference to a font dictionary and size
shall be a number expressed in text space units.
public PdfObject getBlackGenerationFunction()
BG
.
PdfObject
, should be PdfFunction
.
public PdfExtGState setBlackGenerationFunction(PdfObject blackGenerationFunction)
BG
.
blackGenerationFunction
- a PdfObject
, shall be PdfFunction
.
public PdfObject getBlackGenerationFunction2()
Default
, BG2
key.
PdfObject
value, should be either PdfFunction
or PdfName
.
public PdfExtGState setBlackGenerationFunction2(PdfObject blackGenerationFunction2)
Default
, BG2
key. Note, if both BG
and BG2
are present in the same graphics state parameter dictionary, BG2
takes precedence.
blackGenerationFunction2
- a PdfObject
value, shall be either PdfFunction
or Default
.
public PdfObject getUndercolorRemovalFunction()
UCR
key.
PdfObject
, should be PdfFunction
.
public PdfExtGState setUndercolorRemovalFunction(PdfObject undercolorRemovalFunction)
UCR
key.
undercolorRemovalFunction
- a PdfObject
, shall be PdfFunction
.
public PdfObject getUndercolorRemovalFunction2()
Default
, UCR2
key.
PdfObject
value, should be either PdfFunction
or PdfName
.
public PdfExtGState setUndercolorRemovalFunction2(PdfObject undercolorRemovalFunction2)
Default
, UCR2
key. Note, if both UCR
and UCR2
are present in the same graphics state parameter dictionary, UCR2
takes precedence.
undercolorRemovalFunction2
- a PdfObject
value, shall be either PdfFunction
or Default
.
public PdfObject getTransferFunction()
TR
key.
PdfObject
, should be either PdfFunction
, PdfArray
or PdfName
.
public PdfExtGState setTransferFunction(PdfObject transferFunction)
TR
key.
transferFunction
- a PdfObject
, shall be either PdfFunction
, PdfArray
or PdfName
.
public PdfObject getTransferFunction2()
Default
, TR2
key.
PdfObject
, should be either PdfFunction
, PdfArray
or PdfName
.
public PdfExtGState setTransferFunction2(PdfObject transferFunction2)
Default
, TR2
key. Note, if both TR
and TR2
are present in the same graphics state parameter dictionary, TR2
takes precedence.
transferFunction2
- a PdfObject
, shall be either PdfFunction
, PdfArray
, PdfName
or Default
.
public PdfObject getHalftone()
Default
, HT
key.
PdfObject
, should be either PdfDictionary
, PdfStream
or PdfName
.
public PdfExtGState setHalftone(PdfObject halftone)
Default
, HT
key.
halftone
- a PdfObject
, shall be either PdfDictionary
, PdfStream
or PdfName
.
@Deprecated public PdfObject getHTP()
HTP
key.
@Deprecated public PdfExtGState setHTP(PdfObject htp)
HTP
key.
htp
- a PdfObject
.
public Float getFlatnessTolerance()
FL
key.
float
value if exist, otherwise null
.
public PdfExtGState setFlatnessTolerance(float flatnessTolerance)
FL
key.
flatnessTolerance
- a float
value.
public Float getSmothnessTolerance()
SM
key.
float
value if exist, otherwise null
.
public PdfExtGState setSmoothnessTolerance(float smoothnessTolerance)
SM
key.
smoothnessTolerance
- a float
value.
public Boolean getAutomaticStrokeAdjustmentFlag()
SA
key.
boolean
value if exist, otherwise null
.
public PdfExtGState setAutomaticStrokeAdjustmentFlag(boolean strokeAdjustment)
SA
key.
strokeAdjustment
- a boolean
value.
public PdfObject getBlendMode()
BM
key.
public PdfExtGState setBlendMode(PdfObject blendMode)
BM
key.
public PdfObject getSoftMask()
SMask
key.
PdfObject
, should be either PdfName
or PdfDictionary
.
public PdfExtGState setSoftMask(PdfObject sMask)
SMask
key.
sMask
- a PdfObject
, shall be either PdfName
or PdfDictionary
.
public Float getStrokeOpacity()
CA
key.
float
value if exist, otherwise null
.
public PdfExtGState setStrokeOpacity(float strokingAlphaConstant)
CA
key.
strokingAlphaConstant
- a float
value.
public Float getFillOpacity()
ca
key.
float
value if exist, otherwise null
.
public PdfExtGState setFillOpacity(float fillingAlphaConstant)
ca
key.
fillingAlphaConstant
- a float
value.
public Boolean getAlphaSourceFlag()
true
) or opacity values (false
), AIS
key.
boolean
value if exist, otherwise null
.
public PdfExtGState setAlphaSourceFlag(boolean alphaSourceFlag)
true
) or opacity values (false
), AIS
key.
alphaSourceFlag
- if true
- alpha as shape values, if false
— as opacity values.
public Boolean getTextKnockoutFlag()
TK
key.
boolean
value if exist, otherwise null
.
public PdfExtGState setTextKnockoutFlag(boolean textKnockoutFlag)
TK
key.
textKnockoutFlag
- true
if enabled.
public PdfExtGState put(PdfName key, PdfObject value)
key
- key to insert or to override
value
- the value to associate with the specified key
public void flush()
PdfObject
behind this wrapper, you have to ensure that this object is added to the document, i.e. it has an indirect reference. Basically this means that before flushing you need to explicitly call PdfObjectWrapper.makeIndirect(PdfDocument)
. For example: wrapperInstance.makeIndirect(document).flush(); Note that not every wrapper require this, only those that have such warning in documentation.
flush
in class PdfObjectWrapper<PdfDictionary>
protected boolean isWrappedObjectMustBeIndirect()
isWrappedObjectMustBeIndirect
in class PdfObjectWrapper<PdfDictionary>
Copyright © 1998–2016 iText Group NV. All rights reserved.