corelibraries-devexpress-dot-pivotgrid-dot-printing-dot-printappearanceobject-46d3525c.md
Specifies the font used to render the text.
Namespace : DevExpress.PivotGrid.Printing
Assembly : DevExpress.PivotGrid.v25.2.Core.dll
NuGet Packages : DevExpress.PivotGrid.Core, DevExpress.Win.Navigation
public DXFont Font { get; set; }
Public Property Font As DXFont
| Type | Description |
|---|---|
| DXFont |
The font used to render the text.
|
Setting the Font property to the control’s default font, currently used by the user’s operating system, automatically sets the appearance object’s AppearanceOptions.UseFont property to false. If this property is disabled and the current appearance object has a parent, the parent’s font settings are used.
To obtain the font settings specified by the appearance object’s settings, use the AppearanceObject.GetFont method.
The following code snippet (auto-collected from DevExpress Examples) contains a reference to the Font 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.
winforms-dashboard-pivot-custom-export/CS/WinformsExport/Form1.cs#L73
if(!e.IsColumn && e.Value?.ToString()?.Trim() == "Seattle") {
var font = new DXFont(e.Appearance.Font, DXFontStyle.Bold);
e.Appearance.Font = font;
winforms-dashboard-pivot-custom-export/VB/WinFormsExport/Form1.vb#L76
'INSTANT VB NOTE: The variable font was renamed since Visual Basic does not handle local variables named the same as class members well:
Dim font_Renamed = New DXFont(e.Appearance.Font, DXFontStyle.Bold)
e.Appearance.Font = font_Renamed
See Also