Please use. NET 5,. NET 6, NET 7,. NET 8, NET Framework 4.6, NET Framework 4.61, NET Framework 4.7, NET Framework 4.72, NET Framework 4.8, NET Framework 4.81, and. NET Core 3.1 versions

VisualizeOptionsGetDefaultFontFamily 方法

Gets the most appropriate default font family across platforms 获取跨平台最合适的默认字体家族

Definition

命名空间: DeploySharp.Data
程序集: DeploySharp.ImageSharp (在 DeploySharp.ImageSharp.dll 中) 版本:0.0.4+6e8a2e904469617cd59619d666c0e272985c0e33
C#
private static FontFamily GetDefaultFontFamily()

返回值

FontFamily
Located font family/找到的字体家族

备注

Tries common sans-serif fonts first, then Chinese-supporting fonts, finally falls back to first available system font 首先尝试常见无衬线字体,然后尝试支持中文的字体, 最后回退到首个可用系统字体

Throws no exceptions - always returns a font (possibly Arial) 不会抛出异常 - 总是返回一个字体(可能是Arial)

参见