Skip to main content
A newer version of this page is available. .
.NET Framework 4.5.2+

RichEditControlCompatibility.DefaultFontName Property

Gets or sets the name of the font which is the default font for Rich Edit controls in the application.

Namespace: DevExpress.XtraRichEdit

Assembly: DevExpress.RichEdit.v19.1.Core.dll

Declaration

[DefaultValue("Calibri")]
public static string DefaultFontName { get; set; }

Property Value

Type Default Description
String "Calibri"

A string that is the font name.

Example

The static RichEditControlCompatibility.DefaultFontSize and RichEditControlCompatibility.DefaultFontName properties set the default font settings for all RichEditControl instances in the application. It is recommended to place them before initialization of all controls, in the Main method, as illustrated in the following code.

<STAThread> _
Shared Sub Main()
    Application.EnableVisualStyles()
    Application.SetCompatibleTextRenderingDefault(False)
    DevExpress.XtraRichEdit.RichEditControlCompatibility.DefaultFontSize = 8
    DevExpress.XtraRichEdit.RichEditControlCompatibility.DefaultFontName = "Tahoma"
    Application.Run(New Form1())
End Sub

The following code snippet (auto-collected from DevExpress Examples) contains a reference to the DefaultFontName 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.

See Also