PDFPAGE_CurrentTextPositionY
IPDFDocument3 :: PDF page methods

See Also Example
Collapse All

This property returns the Y coordinate of the current text position.

Syntax

DOUBLE PDFPAGE_CurrentTextPositionY { get; }
Value
Y-coordinate of the current text position

Remarks

Equivalent in new interface: IPDFDocument4::GetCurrentTextY.

Example

How to Get the Current Text Position

Delphi
[copy to clipboard]
{ PDF object is supposed to be created }
PDF.BeginDoc;
PDF.PDFPAGE_SetActiveFont('Helvetica', false, false, false, false, 16.0, 0);
curX := PDF.PDFPAGE_CurrentTextPositionX;
curY := PDF.PDFPAGE_CurrentTextPositionY;
// now curX = 132.090667724609
// now curY = 15.3333339691162
PDF.EndDoc;
C/C++
[copy to clipboard]
// PDF object is supposed to be created
PDF->BeginDoc();
PDF->PDFPAGE_SetActiveFont("Helvetica", FALSE, FALSE, FALSE, FALSE, 16.0, 0);
PDF->PDFPAGE_Stroke();
DOUBLE curX = PDF.PDFPAGE_CurrentTextPositionX;
DOUBLE curY = PDF.PDFPAGE_CurrentTextPositionY;
// now curX == 132.090667724609
// now curY == 15.3333339691162
PDF->EndDoc();
C#
[copy to clipboard]
// PDF object is supposed to be created
PDF.BeginDoc();
PDF.PDFPAGE_SetActiveFont("Helvetica", false, false, false, false, 16.0, 0);
double curX = PDF.PDFPAGE_CurrentTextPositionX;
double curY = PDF.PDFPAGE_CurrentTextPositionY;
// now curX == 132.090667724609
// now curY == 15.3333339691162
PDF.EndDoc();
Visual Basic
[copy to clipboard]
' PDF object is supposed to be created
PDF.BeginDoc
PDF.PDFPAGE_SetActiveFont "Helvetica", False, False, False, False, 16.0, 0
PDF.PDFPAGE_TextOut 10, 10, 0.0, "Hello, World."
curX = PDF.PDFPAGE_CurrentTextPositionX
curY = PDF.PDFPAGE_CurrentTextPositionY
' now curX = 132.090667724609
' now curY = 15.3333339691162
PDF.EndDoc

See Also

Reference