统一系统在Android中



我想使用android系统字体显示中文文本。
我使用

var fonts = Font.GetOSInstalledFontNames(); 

记录设备中的字体。我发现这个Noto Sans CJK TC

但是我打电话给

font = (Font)Resources.GetBuiltinResource(typeof(Font), "NotoSansTC-Black.ttf");

它总是显示The resource NotoSansTC-Black.ttf could not be loaded from the resource file!如何在Android设备中使用此字体。谢谢

我认为您想要的是Font.CreateDynamicFontFromOSFont

font = Font.CreateDynamicFontFromOSFont("NotoSansTC-Black", 12);

最新更新