4 Replies Latest reply on Dec 21, 2006 1:46 AM by Newsgroup_User

    Text-to-graphic conversion at runtime

    brandylad
      Hi there,

      Thanks for looking at this post. I have a project in which I've got text being loaded in from an external source, to be displayed in a text field object and dynamically moved about and re-scaled. If anyone has tried to do this with dynamic (or, as I've found out, even static) text objects, you might have noticed that it isn't done very smoothly. From appearances, the display of the text seems to be very dependent on the system's own typeface-display capabilities. In rescaling in particular, transitions between size are jerky as it jumps between held font sizes - very unlike Flash's usual smooth scaling.

      I've tried the exact same moving/scaling functions as in my project on graphic symbols, and also text objects converted to graphic objects through the 'Break Apart' command. In these cases, the scaling looks great; very smooth with no jumping. So I don't have a problem as long as I do this with all the text I use in the project, but I want it to load data in dynamically, so I'm stuck.

      To reiterate what I'm asking: Is there any way to apply this text to graphic conversion on the fly? Or another workaround that anyone can think of? I'm not too sure how well known the jerky-scaling issue is in Flash, but I haven't had much luck trying to read around the subject - so I'd be really grateful for any advice at all.

      Thank you!
      Adam
        • 1. Re: Text-to-graphic conversion at runtime
          Metro Media Level 1
          have you tried putting a text box inside of a holder movie clip and then scaling the holder clip instead of just the text box?
          • 2. Re: Text-to-graphic conversion at runtime
            Level 7
            > Is there any way to apply this text to graphic
            > conversion on the fly?

            No.

            > Or another workaround that anyone can think of?

            Hmm. Possibly. Depends on how much you are going to scale your text, and how
            clean you need the edges to appear. Take a look at the BitmapData Class.
            Perhaps you could create a BitmapData object and copy the contents of your
            text field into it. I haven't tried this, but it should work. You could then
            scale the BitmapData object....



            --
            -------------------------------
            Remove '_spamkiller_' to mail
            -------------------------------


            • 3. Text-to-graphic conversion at runtime
              brandylad Level 1
              Hey, thanks for the responses, and sorry my reply's so late.

              quote:

              have you tried putting a text box inside of a holder movie clip and then scaling the holder clip instead of just the text box?
              - Metro Media
              Good idea, but yeah, unfortunately this doesn't change the way the text is presented.

              quote:

              Take a look at the BitmapData Class.
              Perhaps you could create a BitmapData object and copy the contents of your
              text field into it. I haven't tried this, but it should work. You could then
              scale the BitmapData object....
              - Peter Blumenthal
              Good thinking =) I had a quick play around with this idea but it does look kind of ugly. And to avoid that, I think I'd need pretty huge MCs containing the text to snapshot before I reduce them to use as originally intended. That'd mean a lot of memory usage - probably CPU too - and there would be quite a few textfields. Think I might just stick with my jerky text until Adobe read this thread and take pity on me for the next release. =)
              • 4. Re: Text-to-graphic conversion at runtime
                Level 7
                lol - you're welcome

                --
                -------------------------------
                Remove '_spamkiller_' to mail
                -------------------------------