加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

Flex4中关于无法构建字体错误

发布时间:2020-12-15 03:31:27 所属栏目:百科 来源:网络整理
导读:在Flex4中做一个项目,出现一个错误烦恼了一段时间, 代码是这样的: [Embed(systemFont="宋体", ??????????????? fontName="myFont", ??????????????? mimeType="application/x-font")] 提示错误: 无法构建字体“myFont” 转 换代码时出现意外错误:Cannot

在Flex4中做一个项目,出现一个错误烦恼了一段时间,

代码是这样的:

[Embed(systemFont="宋体",
??????????????? fontName="myFont",
??????????????? mimeType="application/x-font")]

提示错误:

无法构建字体“myFont”

转 换代码时出现意外错误:Cannot embed local font '宋体' as CFF. The CSS @font-face 'local()' syntax is not supported. Please specify a path directly to a font file using the 'url()' syntax. For [Embed] syntax the 'systemFont' attribute is not supported. Please specify a path directly to a font file using the 'source' attribute.

?

通过一个网友的帮助,原来那是flex3中的方法,flex4中发生了变化

?

改过后的代码:

[Embed(systemFont="宋体",
????????? fontName="myFont5",
????mimeType="application/x-font-truetype",
????embedAsCFF="false" )]

flex4中需要加上

mimeType="application/x-font-truetype";

??embedAsCFF="false"?

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读