What the PDETextGetText method writes to textBuffer

Explorer ,
Dec 06, 2019 Dec 06, 2019

Copy link to clipboard

Copied

The Help API says that the PDETextGetText method (PDEText pdeText, ASUns32 flags, ASInt32 index, ASUns8 * textBuffer) gets the text for a text run or character.
textBuffer - the text of the specified character or text run.

I created a PDF file in which I placed the text: abc.

I put the following statements in the code:
ASUns8 buffer [128];
PDETextGetText (pdeText, kPDETextRun, 0, buffer);
The debugger showed that the contents of the first 3 bytes of the buffer are '\ x1', '\ x2', '\ x1'. What then is written in buffer and why does it not match the text from the file?

TOPICS
Acrobat SDK and JavaScript

Views

51

Likes

Translate

Translate

Report

Report
Community Guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
no replies

Have something to add?

Join the conversation