flash/flex Font
zFont.instance.addEventListener(zFontEvent.LOAD_COMPLETE,loadCompleteHandler);
zFont.instance.addEventListener(zFontProgressEvent.PROGRESS,onProgressHandler);
zFont.instance.addEventListener(zFontEvent.LOAD_ERROR,loadErrorHandler);
zFont.instance.loadSWF("assets/font/zFont.swf",true);
function loadCompleteHandler(event:zFontEvent):void
{
zFont.instance.registerFromURL();//注册字体
flexLabel.setStyle("fontFamily","zFont");//flex - CFF
var tf:TextField = new TextField();//flash - unCFF
tf.type = TextFieldType.DYNAMIC;
tf.autoSize = TextFieldAutoSize.LEFT;
tf.embedFonts = true;//嵌入设置
var tft:TextFormat = new TextFormat("zFont", 40,0xFF0000,true);
tf.defaultTextFormat = tft;
tf.text = "ZB";
ui.addChild(tf);
}