PdfGState Object

Overview

PdfGState, introduced in Version 3.1, represents a graphics state object used primarily for transparency-related operations. Also represents a transparency group. This object is created via the PdfDocument.CreateGState method. For more information, see Chapter 19 - Transparency.

Member List

Properties


float Alpha (Read-only)

Returns the stroke alpha value for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.1 - PdfGState Object: Overview.


bool AlphaIsShape (Read-only)

Returns the alpha-is-shape flag for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.5 - Miscellaneous Features.


bool BlendMode (Read-only)

Returns the alpha-is-shape flag for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.2 - Blend Mode.


float FillAlpha (Read-only)

Returns the fill alpha value for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.1 - PdfGState Object: Overview.


float FillAlpha (Read-only)

Returns the fill alpha value for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.1 - PdfGState Object: Overview.


bool FillOverprint (Read-only)

Returns the fill overprint flag for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.5 - Miscellaneous Features.


bool IsGroup (Read-only)

Returns True if this object represents a transparency group, and False if it represents a graphics state object.

For more information, see Section 19.1 - PdfGState Object: Overview.


bool Isolated (Read-only)

Returns the isolated flag for this transparency group. This property can only be used if this object represents a transparency group (IsGroup = True).

For more information, see Section 19.3 - Transparency Groups.


bool Knockout (Read-only)

Returns the knockout flag for this transparency group. This property can only be used if this object represents a transparency group (IsGroup = True).

For more information, see Section 19.3 - Transparency Groups.


bool Overprint (Read-only)

Returns the stroke overprint flag for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.5 - Miscellaneous Features.


int OverprintMode (Read-only)

Returns the overprint mode for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.5 - Miscellaneous Features.


bool TextKnockout (Read-only)

Returns the text knockout flag for this graphics state. This property can only be used if this object represents a graphics state object (IsGroup = False).

For more information, see Section 19.5 - Miscellaneous Features.

Methods


void SetColorSpace(PdfColorSpace ColorSpace)

Specifies a color space for this transparency group. It is necessary call this method if this transparency group is used to represent a soft mask based on luminosity. This method can only be used if this object represents a transparency group (IsGroup = True).

For more information, see Section 19.4 - Soft Masks.


void SetSoftMask(PdfGraphics Graphics, object Param)

Specifies a graphics object whose alpha or luminosity is to be used as a soft mask for this graphics state. The Graphics object must have a transparency group associated with it via the PdfGraphics.SetGroup method. This method can only be used if this object represents a graphics state object (IsGroup = False).

Param is a PdfParam object or parameter string. The following parameters (all optional) are supported:

  • Alpha (Boolean) - if True, specifies that the alpha values of Graphics are to be used for the soft mask. If False or omitted, the luminocity values of Graphics are to be used. In the latter case, the transparency group associated with Graphics must have a color space linked to it via the SetColorSpace method.
  • C0, C1, ..., Cn - the color components in the range 0.0 to 1.0 specifying the color to be used as the backdrop against which to composite the transparency group. Only used if Alpha is False or omitted. The number of color components must match the color space linked to the transparency group associated with Graphics.

For more information, see Section 19.4 - Soft Masks.