THPDFPage.AddLineAnnotation

THPDFPage

 

Topo  Anterior  Próxima

Adiciona nova anotação Line na página atual.

 

Sintaxe Delphi:

procedure AddLineAnnotation ( Contents: AnsiString; BeginPoint: THPDFCurrPoint; EndPoint: THPDFCurrPoint; Color: TColor = clRed );

THPDFCurrPoint Type Definition

TPDFCurrPoint defines a point

Unit
HPDFDoc

type
    THPDFCurrPoint = record
        X: Extended;
        Y: Extended;
end;

Description:
The THPDFCurrPoint type defines a pixel location. X specifies the horizontal coordinate of the point, Y specifies the vertical coordinate.

 

Sintaxe C++:

void __fastcall AddLineAnnotation ( AnsiString Contents, THPDFCurrPoint &BeginPoint, THPDFCurrPoint &EndPoint, Graphics::TColor Color );

 

Descrição

Use AddLineAnnotation para adicionar nova anotação Line mensagem de texto especificada ( Contents), ponto inicial, ponto final e cor na página atual.

 

Sobrecarga com estilos de pontas de linha (HotPDF v2.119.16)

procedure AddLineAnnotation ( Contents: AnsiString; BeginPoint, EndPoint: THPDFCurrPoint; BeginStyle, EndStyle: THPDFLineEndingStyle; Color: TColor = clRed );

Esta sobrecarga emite o array de pontas de linha /LE [/<begin> /<end>] do PDF conforme ISO 32000-1 §12.5.6.7 Table 175 + Table 176. O viewer então renderiza as marcas de pontos finais fornecidas (setas, traços, shapes) sem o chamador precisar desenhá-las na página. THPDFLineEndingStyle cobre o conjunto completo da Table 176:

   lesNone — sem marca de ponto final (padrão da spec PDF)    lesSquare — quadrado preenchido    lesCircle — círculo preenchido    lesDiamond — losango preenchido    lesOpenArrow — ponta de seta aberta    lesClosedArrow — ponta de seta fechada triangular    lesButt — traço curto perpendicular    lesROpenArrow — seta aberta em direção reversa    lesRClosedArrow — seta fechada em direção reversa    lesSlash — traço curto de ~30° em sentido horário

 

Exemplo

PDF.CurrentPage.AddLineAnnotation('Width = 120mm',
  Point1, Point2, lesClosedArrow, lesClosedArrow, clBlue);

 

Line annotation preview