Skip to main content
All docs
V24.1

PdfFreeTextAnnotationFacade.FontName Property

Specifies the annotation’s font name.

Namespace: DevExpress.Pdf

Assembly: DevExpress.Pdf.v24.1.Core.dll

NuGet Package: DevExpress.Pdf.Core

Declaration

public string FontName { get; set; }

Property Value

Type Description
String

The font name.

Remarks

The following example configures the annotation’s text settings:

Customize text in the free text annotation

using DevExpress.Pdf;
// ...
using (PdfDocumentProcessor processor = new PdfDocumentProcessor()) {
    processor.CreateEmptyDocument("Document.pdf");
    processor.AddNewPage(PdfPaperSize.Letter);
    var freeText = processor.DocumentFacade.Pages[0].AddFreeTextAnnotation(new PdfRectangle(80, 80, 400, 120), "Free Text Annotation");
    freeText.FontName = "Times New Roman";
    freeText.FontColor = new PdfRGBColor(0.059, 0.6, 0.224);
    freeText.FontItalic = true;
    freeText.FontBold = true;
    freeText.FontSize = 15;
    freeText.TextJustification = PdfTextJustification.Centered;
    processor.SaveDocument("Document.pdf");
}
See Also