DrawTextBox
Tekst, Pagina-indeling
Beschrijving
Deze functie lijkt op de functie DrawText, maar de tekst wordt binnen de opgegeven bounding box geplaatst. De verticale uitlijning kan met de parameter Options worden ingesteld en de horizontale uitlijning met de functie SetTextAlign. De tekst wordt op woordniveau afgebroken zodat deze binnen de bounding box past
Syntaxis
Delphi
Function TPDFlib.DrawTextBox(Left, Top, Width, Height: Double; Const Text: WideString; Options: Integer): Integer;
ActiveX
Function PDFlib::DrawTextBox(Left As Double, Top As Double, Width As Double, Height As Double, Text As String, Options As Long) As Long
DLL
int DLDrawTextBox(int InstanceID, double Left, double Top, double Width, double Height, const wchar_t * Text, int Options);
Parameters
| Left | De horizontale coördinaat van de linkerrand van de bounding box |
|---|---|
| Top | De verticale coördinaat van de bovenrand van de bounding box |
| Width | De breedte van de bounding box |
| Height | De hoogte van de begrenzingsdoos |
| Text | De tekst die op de pagina moet worden getekend |
| Options | 0 = Center vertical alignment 1 = Top vertical alignment 2 = Bottom vertical alignment 3 = Center vertical alignment, no wrapping 4 = Top vertical alignment, no wrapping 5 = Bottom vertical alignment, no wrapping |
Retourwaarden
| 0 | De parameter Options was buiten bereik, of de parameter Width was te klein om tekst te bevatten |
|---|---|
| Non-zero | Het aantal regels tekst dat daadwerkelijk is getekend |