在Flex3上的AS3中嵌入字体
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了在Flex3上的AS3中嵌入字体相关的知识,希望对你有一定的参考价值。
This describes how to embed font in to Flex(mxml) file without using the tag (fully AS3).
[Embed(source='assets/CALIBRII.TTF', fontName='fontCalibri', fontStyle='italic', fontWeight='light', mimeType='application/x-font')] textFormat = new TextFormat(); textFormat.color = 0xFFFFFF; textFormat.font = "fontCalibri"; textFormat.size = 11; textField = new TextField(); textField.embedFonts = true; textField.text = "Embeded Text"; textField.selectable = false; textField.background = true; textField.multiline = false; textField.backgroundColor = 0x000000; textField.setTextFormat(this.textFormat);
以上是关于在Flex3上的AS3中嵌入字体的主要内容,如果未能解决你的问题,请参考以下文章
ActionScript 3 在AS3中嵌入字体 - 资产类
ActionScript 3 AS3在Flex中嵌入系统字体