Welcome, Guest. Please login or register.
Did you miss your activation email?
05/23/12, 02:36
Home Help Search Login Register
News: Parsley Flex framework review featuring quiz application, in our Flex frameworks series
Flex SDK 4.5 mobile roadmap: begin with your mobile development
Swiz Flex framework review featuring quiz application
New homepage we release our new Homepage, take a look ...

+  Flash-db
|-+  General
| |-+  Flash MX 2004 (Moderators: Flash-db, Musicman, vesa kortelainen, Ronald Wernecke, Andresss, papachan)
| | |-+  dynamically embedding fonts
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Print
Author Topic: dynamically embedding fonts  (Read 588 times)
kristof
Server what's that
*
Posts: 9



View Profile Email
« on: 06/12/04, 07:36 »

is there anyone who can help me with this problem?

Sfont is a font in the library which puts a linkage identifier to a pixelfont (peterpan)
the linkage identifier is = Sfont
As 2.0 class is nothing (tried this but doesn't seem to change anything
export for actionscript is on
export in first frame is on

i used to make this font embedded in FLash MX, now in FLASH MX 2004 there are some problems...  

following code as i would say, has to work, but it doesn't...

myformat = new TextFormat();
myformat.color = 0x0ff000;   --> change this and the color changes
myformat.type = dynamic;
myformat.embedFonts = true;
myformat.font = "Sfont";
myformat.multiline = true;
myformat.wordWrap = true;
myformat.selectable = false; -->still selectable?Huh

_root.languageMC.createTextField("mytext",20,0,0,300,100);
_root.languageMC.mytext.text = "text";
_root.languageMC.mytext.setTextFormat(myformat);

i get a textbox, but not with the requested font... if i change the color for instance, the color does change, but why won't he set the FONT?

thx
« Last Edit: 06/12/04, 07:39 by kristof » Logged
Jorge Solis
Administrator
Systems Administrator
*****
Posts: 14600


View Profile
« Reply #1 on: 06/12/04, 12:31 »

Hi Kristof, welcome to the Boards !

The selectable property is from the TextField, not the text format. Try adding:

_root.languageMC.createTextField("mytext",20,0,0,300,100);
_root.languageMC.mytext.embedFonts = true
_root.languageMC.mytext.text = "text";
_root.languageMC.mytext.setTextFormat(myformat);

Jorge
« Last Edit: 06/12/04, 12:32 by Jorge Solis » Logged

Pages: [1] Print 
« previous next »
Jump to:  


Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!