mirror of
https://github.com/2dust/v2rayN.git
synced 2025-11-29 03:02:53 +00:00
20 lines
556 B
C#
20 lines
556 B
C#
public static AppBuilder WithFontByDefault(this AppBuilder appBuilder)
|
|
{
|
|
var fallbacks = new List<FontFallback>();
|
|
|
|
var notoSansSc = new FontFamily(Path.Combine(Global.AvaAssets, "Fonts#Noto Sans SC"));
|
|
fallbacks.Add(new FontFallback { FontFamily = notoSansSc });
|
|
|
|
if (OperatingSystem.IsLinux())
|
|
{
|
|
fallbacks.Add(new FontFallback
|
|
{
|
|
FontFamily = new FontFamily("Noto Color Emoji")
|
|
});
|
|
}
|
|
|
|
return appBuilder.With(new FontManagerOptions
|
|
{
|
|
FontFallbacks = fallbacks.ToArray()
|
|
});
|
|
}
|