Components for Developers
© 2000-2012, Two Pilots

PDF Library Download Features Manual Tutorials FAQ Pricing HTML2PDF-X Pilot History In the Lab

PDF Creator Pilot documentation

Download CHM version of this manual.
Annotations
PDFANNOTATION_Font_Style_fsUnderline

See Also Example
Collapse All

This property gets or sets the value indicating if the control's font is underlined.

Syntax

VARIANT_BOOL PDFANNOTATION_Font_Style_fsUnderline { get; set; }
Value
VARIANT_TRUE if the control's font is underlined, VARIANT_FALSE otherwise.

Remarks

Each control may contain text that is shown with the default font. You can change any font attributes, such as Character set, Color, Name, Size and Style.

Equivalent in new interface: IPDFDocument4::ControlFont.

Example

Setting a Custom Font for a Control

Delphi
[copy to clipboard]
{ PDF object is supposed to be created }
PDF.BeginDoc;
PDF.PDFPAGE_CreateControl_Edit('edt1', 10, 10, 150, 30);
PDF.PDFANNOTATION_Text := 'Text';
PDF.PDFANNOTATION_Font_Name := 'Times';
PDF.PDFANNOTATION_Font_Color := 255;
PDF.PDFANNOTATION_Font_Charset := charsetANSI_CHARSET;
PDF.PDFANNOTATION_Font_Size := 8;
PDF.PDFANNOTATION_Font_Style_fsBold := true;
PDF.PDFANNOTATION_Font_Style_fsItalic := true;
PDF.PDFANNOTATION_Font_Style_fsStrikeout := true;
PDF.PDFANNOTATION_Font_Style_fsUnderline := true;
PDF.EndDoc;
C/C++
[copy to clipboard]
// PDF object is supposed to be created
PDF->BeginDoc();
PDF->PDFPAGE_CreateControl_Edit("edt1", 10, 10, 150, 30);
PDF->PDFANNOTATION_Text = "Text";
PDF->PDFANNOTATION_Font_Name = "Times";
PDF->PDFANNOTATION_Font_Color = 255; // red
PDF->PDFANNOTATION_Font_Charset = charsetANSI_CHARSET;
PDF->PDFANNOTATION_Font_Size = 8;
PDF->PDFANNOTATION_Font_Style_fsBold = TRUE;
PDF->PDFANNOTATION_Font_Style_fsItalic = TRUE;
PDF->PDFANNOTATION_Font_Style_fsStrikeout = TRUE;
PDF->PDFANNOTATION_Font_Style_fsUnderline = TRUE;
PDF->EndDoc();
C#
[copy to clipboard]
// PDF object is supposed to be created
PDF.BeginDoc();
PDF.PDFPAGE_CreateControl_Edit("edt1", 10, 10, 150, 30);
PDF.PDFANNOTATION_Text = "Text";
PDF.PDFANNOTATION_Font_Name = "Times";
PDF.PDFANNOTATION_Font_Color = 255; // red
PDF.PDFANNOTATION_Font_Charset = TxFontCharset.charsetANSI_CHARSET;
PDF.PDFANNOTATION_Font_Size = 8;
PDF.PDFANNOTATION_Font_Style_fsBold = true;
PDF.PDFANNOTATION_Font_Style_fsItalic = true;
PDF.PDFANNOTATION_Font_Style_fsStrikeout = true;
PDF.PDFANNOTATION_Font_Style_fsUnderline = true;
PDF.EndDoc();
Visual Basic
[copy to clipboard]
' PDF object is supposed to be created
PDF.BeginDoc
PDF.PDFPAGE_CreateControl_Edit "edt1", 10, 10, 150, 30
PDF.PDFANNOTATION_Text = "Text"
PDF.PDFANNOTATION_Font_Name = "Times"
PDF.PDFANNOTATION_Font_Color = 255
PDF.PDFANNOTATION_Font_Charset = 0 'charsetANSI_CHARSET
PDF.PDFANNOTATION_Font_Size = 8
PDF.PDFANNOTATION_Font_Style_fsBold = True
PDF.PDFANNOTATION_Font_Style_fsItalic = True
PDF.PDFANNOTATION_Font_Style_fsStrikeout = True
PDF.PDFANNOTATION_Font_Style_fsUnderline = True
PDF.EndDoc

See Also

PDF Library Download Features Manual Tutorials FAQ Pricing HTML2PDF-X Pilot History In the Lab

 

 

PDF Library | Virtual Printer | Converters to PDF

Support | Blog | Forum | Contacts

© 2000-2012, Two Pilots