PDF Creator Pilot documentation |
Download CHM version of this manual. |
|
![]() ![]() Collapse AllBegins text-related operations block and switches PDF page to text mode.
|
| HRESULT PDFPAGE_BeginText () |
Return value
If successful, this method returns S_OK. If it fails, this method should return one of the error values.
Remarks
This method starts a logical text block and should be called before any text output operators. But it is not necessary, the page will call this method automatically when needed.
Example
Switching to text mode and back
Delphi
[copy to clipboard]
{ PDF object is supposed to be created }
PDF.BeginDoc;
PDF.PDFPAGE_BeginText;
PDF.PDFPAGE_SetActiveFont('Helvetica', false, false, false, false, 14.0, 0);
PDF.PDFPAGE_TextOut(20, 20, 0.0, 'Text line.');
PDF.PDFPAGE_EndText;
PDF.PDFPAGE_Ellipse(50, 50, 160, 140);
PDF.PDFPAGE_Stroke;
PDF.EndDoc;
C/C++
[copy to clipboard]
// PDF object is supposed to be created
PDF->BeginDoc();
PDF->PDFPAGE_BeginText();
PDF->PDFPAGE_SetActiveFont("Helvetica", FALSE, FALSE, FALSE, FALSE, 14.0, 0);
PDF->PDFPAGE_TextOut(20, 20, 0.0, "Text line.");
PDF->PDFPAGE_EndText();
PDF->PDFPAGE_Ellipse(50, 50, 160, 140);
PDF->PDFPAGE_Stroke();
PDF->EndDoc();
C#
[copy to clipboard]
// PDF object is supposed to be created
PDF.BeginDoc();
PDF.PDFPAGE_BeginText();
PDF.PDFPAGE_SetActiveFont("Helvetica", false, false, false, false, 14.0, 0);
PDF.PDFPAGE_TextOut(20, 20, 0.0, "Text line.");
PDF.PDFPAGE_EndText();
PDF.PDFPAGE_Ellipse(50, 50, 160, 140);
PDF.PDFPAGE_Stroke();
PDF.EndDoc();
Visual Basic
[copy to clipboard]
' PDF object is supposed to be created PDF.BeginDoc PDF.PDFPAGE_BeginText PDF.PDFPAGE_SetActiveFont "Helvetica", False, False, False, False, 14.0, 0 PDF.PDFPAGE_TextOut 20, 20, 0.0, "Text line." PDF.PDFPAGE_EndText PDF.PDFPAGE_Ellipse 50, 50, 160, 140 PDF.PDFPAGE_Stroke PDF.EndDoc
See Also
Reference


