DL Logo

PDEText Functions

PDETextAddASText

Header: DLExtrasProcs.h:365

Description

Adds a character or a text run to a PDEText object, taking them from the ASText; thus Unicode characters can be placed in the PDEText. This function will accept characters that are not representable in the given font; such characters will be replaced with the.notdef glyph.

An exception will be raised if the supplied font is incompatible with the API. Such may happen, for example, if font is a Type 1 font or if the font is retrieved from an existing PDF document.

Syntax

void PDETextAddASText(PDEText pdeText, ASUns32 flags, ASInt32 index, ASText text, PDEFont font, PDEGraphicStateP gstateP, ASUns32 gstateLen, PDETextStateP tstateP, ASUns32 tstateLen, ASFixedMatrixP textMatrixP);

Parameters

pdeText
The text object to which a character or text run is added.
flags
A PDETextFlags that specifies what kind of text to add.
index
The index after which to add the character or text run.
text
An ASText containing the text to add
font
The PDEFont for the element. Its type must be 'Type0' or 'TrueType'.
gstateP
A pointer to a PDEGraphicStateP structure with the graphics state for the element.
gstateLen
The length of the graphics state for the element.
tstateP
A pointer to a PDETextState structure with the text state for the element.
tstateLen
The length of the text state for the element.
textMatrixP
A pointer to an ASFixedMatrix that holds the matrix for the element.

PDETextGetASText

Header: DLExtrasProcs.h:416

Description

Gets the text for a text run or character. The PDEFont associated with the PDEText must contain a ToUnicode table unless the descendant CIDFont uses the Adobe-GB1, Adobe-CNS1, Adobe-Japan1, or Adobe-Korea1 character collection.

Related Methods

Syntax

void PDETextGetASText(PDEText pdeText, ASUns32 flags, ASInt32 index, ASText text);

Parameters

pdeText
A text object containing a character or text run whose text is found
flags
A PDETextFlags that specifies whether index refers to a character or a text run.
index
The index of the character or text run in pdeText
text
An ASText that is filled with the text from the text item