Hello Aaron,

On 06/05/2010, aaronius9er9er <aaronius...@gmail.com> wrote:
>
> We have an app built in Flex 3.3.  We've pulled the text layout framework
> swc from Flex 4 to use in our app.  We now need to load fonts dynamically at
> runtime to use within our text flow.  In my understanding, in order to

We've also had to use the TLF with CFF fonts in a Flex 3.* app... we didn't
have to load them at runtime but we compiled a swc with them and linked that on
the main app.

Perhaps you could do something like that with a RSL if you need to load them
dynamically.

But, most importantly, for the fonts to be linked you don't really need the swf
 compiled with the new sdk to be a full flex app.  In our case it was just a
plain class with the fonts embedded:

package uk.co.razorfish.fonts
{

/**
 *  This class embedds the fonts needed for the TLF which is used for the
    ...
 */
public class EmbeddedFonts
{

    [Embed(
        source="tt1047m_.ttf",
        fontFamily="Industrial736 BT",
        fontStyle="regular",
        cff="true",
        advancedAntiAliasing="true",
        unicodeRange="U+0020-007F, U+00A0-00FF, U+2010-201F,
U+2032-2037, U+2039-203A, U+20A0-20B5"
    )]
    public static const INDUSTRIAL_ROMAN:Class;

    [Embed(
        source="tt1048m_.ttf",
        fontFamily="Industrial736 BT",
        fontStyle="italic",
        cff="true",
        advancedAntiAliasing="t

... etc.

Because we needed to load them up front, on the main app, we just linked that
class,

import uk.co.razorfish.fonts.EmbeddedFonts; EmbeddedFonts;

And that did the job.

HTH,
Gabriel

-- 
gabriel montagné láscaris comneno
http://rojored.com
+44 (0) 7500 709 209

Reply via email to