officefileapi-devexpress-dot-pdf-dot-pdfstringformat-a40bf41d.md
Gets a generic default PdfStringFormat object.
Namespace : DevExpress.Pdf
Assembly : DevExpress.Pdf.v25.2.Core.dll
NuGet Package : DevExpress.Pdf.Core
public static PdfStringFormat GenericDefault { get; }
Public Shared ReadOnly Property GenericDefault As PdfStringFormat
| Type | Description |
|---|---|
| PdfStringFormat |
The generic default PdfStringFormat object.
|
The following table shows initial property values for a generic default instance of the GenericDefault class.
| Property | Initial Value |
|---|---|
| FormatFlags | 0 |
| Alignment | Near |
| LineAlignment | Near |
| Trimming | Character |
| HotkeyPrefix | None |
| LeadingMarginFactor | 1/6 |
| TrailingMarginFactor | 1/6 |
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the GenericDefault property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
pdf-document-api-add-graphics-to-landscape-and-portrait-pages/CS/CreateGraphics/Program.cs#L35
DXFont font = new DXFont("Segoe UI", 20, DXFontStyle.Regular);
SizeF textSize = graphics.MeasureString(text, font, PdfStringFormat.GenericDefault, DrawingDpi, DrawingDpi);
PointF topLeft = new PointF(0, 0);
pdf-document-api-add-graphics-to-landscape-and-portrait-pages/VB/CreateGraphics/Program.vb#L30
Dim font As DXFont = New DXFont("Segoe UI", 20, DXFontStyle.Regular)
Dim textSize As SizeF = graphics.MeasureString(text, font, PdfStringFormat.GenericDefault, DrawingDpi, DrawingDpi)
Dim topLeft As PointF = New PointF(0, 0)
See Also