com.itextpdf.text.pdf
Class PdfGState

java.lang.Object
  extended by com.itextpdf.text.pdf.PdfObject
      extended by com.itextpdf.text.pdf.PdfDictionary
          extended by com.itextpdf.text.pdf.PdfGState

public class PdfGState
extends PdfDictionary

The graphic state dictionary.

Author:
Paulo Soares

Field Summary
static PdfName BM_COLORBURN
          A possible blend mode
static PdfName BM_COLORDODGE
          A possible blend mode
static PdfName BM_COMPATIBLE
          A possible blend mode
static PdfName BM_DARKEN
          A possible blend mode
static PdfName BM_DIFFERENCE
          A possible blend mode
static PdfName BM_EXCLUSION
          A possible blend mode
static PdfName BM_HARDLIGHT
          A possible blend mode
static PdfName BM_LIGHTEN
          A possible blend mode
static PdfName BM_MULTIPLY
          A possible blend mode
static PdfName BM_NORMAL
          A possible blend mode
static PdfName BM_OVERLAY
          A possible blend mode
static PdfName BM_SCREEN
          A possible blend mode
static PdfName BM_SOFTLIGHT
          A possible blend mode
 
Fields inherited from class com.itextpdf.text.pdf.PdfDictionary
CATALOG, FONT, hashMap, OUTLINES, PAGE, PAGES
 
Fields inherited from class com.itextpdf.text.pdf.PdfObject
ARRAY, BOOLEAN, bytes, DICTIONARY, INDIRECT, indRef, NAME, NOTHING, NULL, NUMBER, STREAM, STRING, TEXT_PDFDOCENCODING, TEXT_UNICODE, type
 
Constructor Summary
PdfGState()
           
 
Method Summary
 void setAlphaIsShape(boolean ais)
          The alpha source flag specifying whether the current soft mask and alpha constant are to be interpreted as shape values (true) or opacity values (false).
 void setBlendMode(PdfName bm)
          The current blend mode to be used in the transparent imaging model.
 void setFillOpacity(float ca)
          Sets the current stroking alpha constant, specifying the constant shape or constant opacity value to be used for nonstroking operations in the transparent imaging model.
 void setOverPrintMode(int opm)
          Sets the flag whether to toggle knockout behavior for overprinted objects.
 void setOverPrintNonStroking(boolean op)
          Sets the flag whether to apply overprint for non stroking painting operations.
 void setOverPrintStroking(boolean op)
          Sets the flag whether to apply overprint for stroking.
 void setRenderingIntent(PdfName ri)
          Set the rendering intent, possible values are: PdfName.ABSOLUTECOLORIMETRIC, PdfName.RELATIVECOLORIMETRIC, PdfName.SATURATION, PdfName.PERCEPTUAL.
 void setStrokeOpacity(float ca)
          Sets the current stroking alpha constant, specifying the constant shape or constant opacity value to be used for stroking operations in the transparent imaging model.
 void setTextKnockout(boolean tk)
          Determines the behavior of overlapping glyphs within a text object in the transparent imaging model.
 void toPdf(PdfWriter writer, OutputStream os)
          Writes the PDF representation of this PdfDictionary as an array of byte to the given OutputStream.
 
Methods inherited from class com.itextpdf.text.pdf.PdfDictionary
checkType, clear, contains, get, getAsArray, getAsBoolean, getAsDict, getAsIndirectObject, getAsName, getAsNumber, getAsStream, getAsString, getDirectObject, getKeys, isCatalog, isFont, isOutlineTree, isPage, isPages, merge, mergeDifferent, put, putAll, putEx, remove, size, toString
 
Methods inherited from class com.itextpdf.text.pdf.PdfObject
canBeInObjStm, getBytes, getIndRef, isArray, isBoolean, isDictionary, isIndirect, isName, isNull, isNumber, isStream, isString, length, setContent, setIndRef, type
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

BM_NORMAL

public static final PdfName BM_NORMAL
A possible blend mode


BM_COMPATIBLE

public static final PdfName BM_COMPATIBLE
A possible blend mode


BM_MULTIPLY

public static final PdfName BM_MULTIPLY
A possible blend mode


BM_SCREEN

public static final PdfName BM_SCREEN
A possible blend mode


BM_OVERLAY

public static final PdfName BM_OVERLAY
A possible blend mode


BM_DARKEN

public static final PdfName BM_DARKEN
A possible blend mode


BM_LIGHTEN

public static final PdfName BM_LIGHTEN
A possible blend mode


BM_COLORDODGE

public static final PdfName BM_COLORDODGE
A possible blend mode


BM_COLORBURN

public static final PdfName BM_COLORBURN
A possible blend mode


BM_HARDLIGHT

public static final PdfName BM_HARDLIGHT
A possible blend mode


BM_SOFTLIGHT

public static final PdfName BM_SOFTLIGHT
A possible blend mode


BM_DIFFERENCE

public static final PdfName BM_DIFFERENCE
A possible blend mode


BM_EXCLUSION

public static final PdfName BM_EXCLUSION
A possible blend mode

Constructor Detail

PdfGState

public PdfGState()
Method Detail

setOverPrintStroking

public void setOverPrintStroking(boolean op)
Sets the flag whether to apply overprint for stroking.

Parameters:
op -

setOverPrintNonStroking

public void setOverPrintNonStroking(boolean op)
Sets the flag whether to apply overprint for non stroking painting operations.

Parameters:
op -

setOverPrintMode

public void setOverPrintMode(int opm)
Sets the flag whether to toggle knockout behavior for overprinted objects.

Parameters:
opm - - accepts 0 or 1

setStrokeOpacity

public void setStrokeOpacity(float ca)
Sets the current stroking alpha constant, specifying the constant shape or constant opacity value to be used for stroking operations in the transparent imaging model.

Parameters:
ca -

setFillOpacity

public void setFillOpacity(float ca)
Sets the current stroking alpha constant, specifying the constant shape or constant opacity value to be used for nonstroking operations in the transparent imaging model.

Parameters:
ca -

setAlphaIsShape

public void setAlphaIsShape(boolean ais)
The alpha source flag specifying whether the current soft mask and alpha constant are to be interpreted as shape values (true) or opacity values (false).

Parameters:
ais -

setTextKnockout

public void setTextKnockout(boolean tk)
Determines the behavior of overlapping glyphs within a text object in the transparent imaging model.

Parameters:
tk -

setBlendMode

public void setBlendMode(PdfName bm)
The current blend mode to be used in the transparent imaging model.

Parameters:
bm -

setRenderingIntent

public void setRenderingIntent(PdfName ri)
Set the rendering intent, possible values are: PdfName.ABSOLUTECOLORIMETRIC, PdfName.RELATIVECOLORIMETRIC, PdfName.SATURATION, PdfName.PERCEPTUAL.

Parameters:
ri -
Since:
5.0.2

toPdf

public void toPdf(PdfWriter writer,
                  OutputStream os)
           throws IOException
Description copied from class: PdfDictionary
Writes the PDF representation of this PdfDictionary as an array of byte to the given OutputStream.

Overrides:
toPdf in class PdfDictionary
Parameters:
writer - for backwards compatibility
os - the OutputStream to write the bytes to.
Throws:
IOException


Copyright © 2014. All Rights Reserved.