【问题标题】:unity system fonts in androidandroid中的统一系统字体
【发布时间】:2019-07-15 05:13:33
【问题描述】:

我想用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 设备中使用此字体。 谢谢

【问题讨论】:

    标签: android unity3d fonts system-font


    【解决方案1】:

    我想你想要的是Font.CreateDynamicFontFromOSFont

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

    【讨论】:

      猜你喜欢
      • 2011-04-19
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-05-14
      • 1970-01-01
      • 2012-11-28
      • 2018-07-30
      相关资源
      最近更新 更多