为什么从 FlashDevelop 导入后 SWC 上的文本不显示?
我为我的项目创建了许多带有图形和代码的 SWC,以便编译时间具有真正更好的性能。我刚刚发现一个问题,很难。
SWC 之一是“文本容器”。它只是一组带有动态文本字段的图形。当我从 Flash CS5.5 应用程序导入 SWC 时,它表现正常。我的意思是:
var swcInstance:SwcClass = new SwcClass
swcInstance.textFiel.text = "hello world!"
addChild(swcInstance)
swcInstance 对象显示在屏幕上,其中包含文本。当我在 FlashDevelop 上执行相同操作时,很困难,它出现在屏幕上,但未显示文本。这是一个已知的错误吗?我做错了什么吗?
编辑: 我使用带有阴影滤镜的 Impact 字体。另外,我做了另一个测试,静态文本字段工作正常。
编辑2: Arial 部分也会出现同样的问题。有些字母不会显示,但其他字母会显示。当我嵌入“All”时,它与 Arial 配合得很好。但即使我将“All”嵌入到 Impact 中,它也无法正常工作,任何内容都会出现。
I created many SWCs with graphics and code for my project so that the compiling time has a really better performance. I just found a problem, tough.
One of the SWCs is a 'text container'. It is just a set of graphics with a dynamic text field in it. When I import the SWC from Flash CS5.5 apps, it behaves normally. I mean:
var swcInstance:SwcClass = new SwcClass
swcInstance.textFiel.text = "hello world!"
addChild(swcInstance)
and the swcInstance object is shown on screen with the text in it. When I do the same on FlashDevelop, tough, it appears on screen but text is not shown. Is this a known bug? Am I doing something wrong?
EDIT:
I'm using Impact font with a drop shadow filter. Also, I made another test and Static text fields work properly.
EDIT 2:
The same problem happens partially with Arial. Some letters don't show up but others do. When I embed "All", it works fine with Arial. But even when I embed "All" with Impact it refuses to work, anything shows up.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
将
embedAsCFF
参数设置为false
在这里阅读更多相关信息:http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf6320a-7fec.html
这里:
http://www.flashdevelop.org/community/viewtopic.php ?f=13&t=6456
Set the
embedAsCFF
parameter tofalse
Read more about that here: http://help.adobe.com/en_US/flex/using/WS2db454920e96a9e51e63e3d11c0bf6320a-7fec.html
And here:
http://www.flashdevelop.org/community/viewtopic.php?f=13&t=6456
对我来说,听起来您可能将这些字体包含在其他 SWC 中 - 如果编译器首先包含这些 SWC,则它们包含的字体可能会隐藏其他 SWC 的字体。
您可以尝试取消添加项目的所有 SWC,然后从具有完整字体的 SWC 开始将它们添加回来。
PS:不要“嵌入字体的所有”字符,选择适当的字符集 - 通常是“Basic Latin”(美国)和“Latin 1”(重音字符)。
To me it sounds like you may have these fonts included in other SWCs - if these SWCs are included first by the compiler the font they contain may hide other SWCs' fonts.
You could try un-adding all SWCs of your project, then adding them back starting with those with complete fonts.
PS: don't "embed all" chars of a font, choose the appropriate charsets - typically "Basic Latin" (US) and "Latin 1" (accented characters).