带有 arial 常规和 arial 粗体的文本字段在 flashcs5 中不能一起使用吗?
我在 MovieClip 中有两个动态经典文本字段,一个嵌入了 Arial Regular,另一个嵌入了 Arial Bold,但第二个 TextField 不显示粗体文本。它显示常规文本。这是我的做法:
一只忙碌的猫 http://cubixshade.com/textz/sample.jpg
我使用两个字段的文本
mc.txt1.text="changed text90";
mc.txt2.text="changed text90";
都以 Arial 常规样式显示。
I have two dynamic classic TextFields in a MovieClip, one with Arial Regular embedded and the other with Arial Bold, but the second TextField is not showing the bold text. It shows regular text. Here is how I am doing it:
a busy cat http://cubixshade.com/textz/sample.jpg
I change the text of two fields using
mc.txt1.text="changed text90";
mc.txt2.text="changed text90";
Both are shown in Arial Regular style.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
当您使用嵌入字体时,您需要知道:
当
TextField
到达舞台时,闪光灯会自动将其上的所有字体类型属性消除为基本属性。在这种情况下,您有 Arial Regular。嵌入字体意味着您将能够在基于
html
的文本字段中使用它们。确保当您“嵌入字体”时,它正在导出为 AS3。在其他情况下,仅当您将字体附加到舞台上的任何文本字段时,该字体才可用。
在这种情况下,您应该正确嵌入字体并稍微更改代码:
When you are working with embeded fonts you need to know:
that when
TextField
hits the stage flash automaticaly dismisses all of the Font type properties on it to the basic one. in this case you have Arial Regular.Embeding fonts means that you will be able to use them in the
html
based TextFields.Make sure that when you are "embeding font" it is beeing exported for AS3. in other case the font will be available only if you had it attached to any textfield that is on stage.
in this case you should propertly embed font and change you code a bit:
我注意到在 Flash 中使用字体时,某些字体即使嵌入它们也无法正确显示,只需尝试另一种字体,一切都会好起来的
i noticed when working with fonts in flash that some font won't diplay correctelly even when i embedded them just try another font and everything gonna be alright
我发现根据字体的不同,粗体版本并不是不同的字体。要变得粗体,您只需要在使用常规字体的 html 文本周围使用标签
I found that depending on the font, the bold version isn't a different font-face. To get bold you only need to use tags around your html text that uses your regular font