Table of Contents

Class PdfTemplate

Namespace
iTextSharp.text.pdf
Assembly
iTextSharp.LGPLv2.Core.dll

Implements the form XObject.

public class PdfTemplate : PdfContentByte
Inheritance
PdfTemplate
Derived
Inherited Members

Constructors

PdfTemplate()

protected PdfTemplate()

Fields

BBox

The bounding box of this template

protected Rectangle BBox

Field Value

Rectangle

TYPE_IMPORTED

public const int TYPE_IMPORTED = 2

Field Value

int

TYPE_PATTERN

public const int TYPE_PATTERN = 3

Field Value

int

TYPE_TEMPLATE

public const int TYPE_TEMPLATE = 1

Field Value

int

ThisReference

The indirect reference to this template

protected PdfIndirectReference ThisReference

Field Value

PdfIndirectReference

group

protected PdfTransparencyGroup group

Field Value

PdfTransparencyGroup

layer

protected IPdfOcg layer

Field Value

IPdfOcg

matrix

protected PdfArray matrix

Field Value

PdfArray

pageResources

The resources used by this template

protected PageResources pageResources

Field Value

PageResources

type

protected int type

Field Value

int

Properties

BoundingBox

public Rectangle BoundingBox { get; set; }

Property Value

Rectangle

Duplicate

public override PdfContentByte Duplicate { get; }

Property Value

PdfContentByte

Group

public virtual PdfTransparencyGroup Group { get; set; }

Property Value

PdfTransparencyGroup

Height

public float Height { get; set; }

Property Value

float

IndirectReference

public PdfIndirectReference IndirectReference { get; }

Property Value

PdfIndirectReference

Layer

Gets the bounding heigth of this template.

public IPdfOcg Layer { get; set; }

Property Value

IPdfOcg

heigth the bounding height

Type

Gets a duplicate of this PdfTemplate . All the members are copied by reference but the buffer stays different.

public int Type { get; }

Property Value

int

a copy of this PdfTemplate

Width

Gets the bounding width of this template.

public float Width { get; set; }

Property Value

float

width the bounding width

Methods

BeginVariableText()

Gets the indirect reference to this template.

public void BeginVariableText()

CreateTemplate(PdfWriter, float, float)

Creates a new template. Creates a new template that is nothing more than a form XObject. This template can be included in this PdfContentByte or in another template. Templates are only written to the output when the document is closed permitting things like showing text in the first page that is only defined in the last page.

public static PdfTemplate CreateTemplate(PdfWriter writer, float width, float height)

Parameters

writer PdfWriter
width float

the bounding box width

height float

the bounding box height

Returns

PdfTemplate

the templated created

EndVariableText()

public void EndVariableText()

SetMatrix(float, float, float, float, float, float)

public void SetMatrix(float a, float b, float c, float d, float e, float f)

Parameters

a float
b float
c float
d float
e float
f float