Table of Contents

Class TransparentColor

Namespace
iText.Layout.Properties
Assembly
itext.layout.dll

Represents a color with the specified opacity.

public class TransparentColor
Inheritance
TransparentColor
Inherited Members

Constructors

TransparentColor(Color)

Creates a new TransparentColor instance of certain fully opaque color.

public TransparentColor(Color color)

Parameters

color Color

the Color of the created TransparentColor object

TransparentColor(Color, float)

Creates a new TransparentColor.

public TransparentColor(Color color, float opacity)

Parameters

color Color

the Color of the created TransparentColor object

opacity float

a float defining the opacity of the color; a float between 0 and 1, where 1 stands for fully opaque color and 0 - for fully transparent

Methods

ApplyFillTransparency(PdfCanvas)

Sets the opacity value for non-stroking operations in the transparent imaging model.

public virtual void ApplyFillTransparency(PdfCanvas canvas)

Parameters

canvas PdfCanvas

the PdfCanvas to be written to

ApplyStrokeTransparency(PdfCanvas)

Sets the opacity value for stroking operations in the transparent imaging model.

public virtual void ApplyStrokeTransparency(PdfCanvas canvas)

Parameters

canvas PdfCanvas

the PdfCanvas to be written to

GetColor()

Gets the color.

public virtual Color GetColor()

Returns

Color

a Color

GetOpacity()

Gets the opacity of color.

public virtual float GetOpacity()

Returns

float

a float between 0 and 1, where 1 stands for fully opaque color and 0 - for fully transparent