Back to Devexpress

ControlBase.Font Property

windowsforms-devexpress-dot-utils-dot-controls-dot-controlbase-65343685.md

latest1.6 KB
Original Source

ControlBase.Font Property

Gets or sets the control font.

Namespace : DevExpress.Utils.Controls

Assembly : DevExpress.Utils.v25.2.dll

NuGet Packages : DevExpress.Utils, DevExpress.Wpf.Core

Declaration

csharp
public override Font Font { get; set; }
vb
Public Overrides Property Font As Font

Property Value

TypeDescription
Font

The control font.

|

Remarks

If a control that derives from this ControlBase class has its own Appearance properties section, ControlBase.Font is synchronized with AppearanceObject.Font.

csharp
Font myFont = new Font("Tahoma", 24f);

textEdit1.Properties.Appearance.Font = myFont;
//or
textEdit1.Font = myFont;
vb
Dim myFont As New Font("Tahoma", 24F)

textEdit1.Properties.Appearance.Font = myFont
'or
textEdit1.Font = myFont

See Also

ControlBase Class

ControlBase Members

DevExpress.Utils.Controls Namespace