THPDFPage.AddFreeTextAnnotation

THPDFPage

 

Top  Previous  Next

Adds new FreeText annotation on the current page.

 

type

  THPDFFreeTextAnnotationJust = ( ftLeftJust, ftCenter, ftRightJust );

 

Delphi syntax:

procedure AddFreeTextAnnotation ( Contents: AnsiString; Rectangle: TRect; Quadding: THPDFFreeTextAnnotationJust; Colour: TColor = clRed );

 

C++ syntax:

void __fastcall AddFreeTextAnnotation ( AnsiString Contents, Windows::TRect &Rectangle, THPDFFreeTextAnnotationJust Quadding, Graphics::TColor Colour );

 

Description

Use AddFreeTextAnnotation to add new FreeText annotation specified text message ( Contents), rectangle area ( Rectangle ), justification ( Quadding ) and colour on the current page.  

 

Value                Meaning


ftLeftJust                    Left justification.

ftCenter                Centre justification.

ftRightJust                Right justification.

 

Contents beyond ASCII (Chinese, Japanese, Korean, Arabic, Cyrillic and so on) travel as UTF-8 through the AnsiString overload or as a WideString. Such an annotation receives its own appearance that draws the text at 12 pt in the page's current font, so pick a font covering the characters with SetFont before adding the annotation. The font is embedded together with the page text, the lines wrap to the rectangle and follow Quadding. ASCII-only contents keep the plain annotation, which viewers draw in Helvetica; under PDF/A and PDF/X, where an unembedded Helvetica is not allowed, they are drawn in the embedded page font as well

 

Free text annotation preview