OK, here are some options:

HTH

Cor


/*
Create in library: New Font
My embedded fonts have Linkage classes of "FFFInterface", "LasVegasD" and
"Wdings". 
Both of these seemed to work for me.
Fonts should be on the develop PC
*/
//TextFormat example
var fmt1:TextFormat = new TextFormat();
fmt1.font = new FFFInterface().fontName;
fmt1.size = 18;

var fmt2:TextFormat = new TextFormat(); 
fmt2.font = new LasVegasD().fontName; 
fmt2.size = 18;

var txt:TextField = new TextField();
txt.width = 400;
txt.embedFonts = true;
txt.text="ActionScript";
//set textformat from beginIndex to EndIndex
txt.setTextFormat(fmt1,0,6);
txt.setTextFormat(fmt2,6,12);
txt.y = 10;
addChild(txt);


//CSS Example
var style:StyleSheet = new StyleSheet();

var heading:Object = new Object();
heading.fontFamily = new Wdings().fontName;
heading.fontSize="24";
heading.fontWeight="bold";
heading.fontStyle="italic";
heading.color="#FF0000";

var body:Object = new Object();
body.fontFamily = new LasVegasD().fontName;
body.fontSize="24";
body.fontWeight="bold";
body.fontStyle="italic";
body.color="#0000FF";

style.setStyle(".heading", heading);
style.setStyle("body", body);

var label:TextField = new TextField();
label.width = 400;
label.embedFonts = true;
label.styleSheet=style;
label.htmlText="<body><span class='heading'>Hello</span> World...</body>";
label.y = 80;
addChild(label);

_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to