SystemFonts.DefaultFont 属性
定义
获取应用程序可用于对话框和窗体的默认字体。Gets the default font that applications can use for dialog boxes and forms.
public:
static property System::Drawing::Font ^ DefaultFont { System::Drawing::Font ^ get(); };
public static System.Drawing.Font DefaultFont { get; }
member this.DefaultFont : System.Drawing.Font
Public Shared ReadOnly Property DefaultFont As Font
属性值
系统的默认 Font。The default Font of the system. 根据用户的操作系统以及系统的本地区域性设置的不同,返回的值也将不同。The value returned will vary depending on the user's operating system and the local culture setting of their system.
注解
下表描述了由属性返回的值, DefaultFont 具体取决于操作系统和本地区域性。The following table describes the value returned by the DefaultFont property depending on the operating system and local culture.
| 系统和/或区域性System and/or culture | 字体Font |
|---|---|
| Windows NT 4x,日语版Windows NT 4x, Japanese version | MS UI 哥特,9点MS UI Gothic, 9 point |
| 阿拉伯 WindowsArabic Windows | Tahoma,8磅Tahoma, 8 point |
| 其他操作系统/区域性Other operating system/culture | MS Shell Dlg 逻辑字体,通常为 Microsoft Sans Serif,8磅MS Shell Dlg logical font, typically Microsoft Sans Serif, 8 point |
MS Shell Dlg 映射到系统注册表中的字体集。MS Shell Dlg maps to a font set in the system registry.
如果未安装上述字体,则默认字体为 Tahoma,8磅。If the above fonts are not installed, the default font is Tahoma, 8 point. 如果未安装 Tahoma、8点,则 DefaultFont 返回属性的值 GenericSansSerif 。If Tahoma, 8 point, is not installed, DefaultFont returns the value of the GenericSansSerif property.
Font DefaultFont 当用户处于高对比度模式时,返回的不会更改。The Font returned by DefaultFont does not change when the user is in High Contrast mode. 对于用户处于高对比度模式时更改的字体,请使用其他系统字体,如 IconTitleFont 。For a font that changes when the user is in High Contrast mode use another system font such as IconTitleFont.