4 Replies Latest reply on Jun 21, 2006 6:38 PM by woodtah

    Font size changes when textfield height changes

    woodtah
      I have a textfield that I drew on the stage. It has a width of 450, and a height of 100. I am using a StyleSheet object to format the text. When I go back and modify the height of the textfield in the propery inspector, the font size changes along with it. When I increase the height, the font-size increases, and when I decrease the height, the font-size decreases.

      Can anyone tell me why this is happening? I am using Flash MX 2004 Pro, with the export settings for Flash 7.

      The code I am using is below:

        • 1. Re: Font size changes when textfield height changes
          jtouhey
          assuming this is a dynamic text field, to avoid scaling the actual text within the field, click inside the text field (with the text tool)- you will see a small box in the bottom right hand corner, use this to scale the text field vertically or horz.... it will not effect the font size.
          • 2. Re: Font size changes when textfield height changes
            woodtah Level 1
            You are right, this is a dynamic text field.

            I guess I am not really understanding what is going on. Why does the text scale at all when I change the height and width of the textfield using the property inspector? If I want a textfield on the page to be 100 x 100 and have a font size of 24 pixels, shouldn't I just be able to draw a textfield on the stage, go to the property inspector and change the size, set the font and the x and y coordinates? If I decide later that I really wanted the text field to be 200 x 200, I should just be able to modify the height and width properties, while everything else (including the font size) stays the same, correct? At what point does the scaling start to happen when modifying the size of the textfield?
            • 3. Re: Font size changes when textfield height changes
              injpix Level 3
              When you change the width and height values in the property panel you are actually transforming it. This acts the same way as the Free Transform Tool. The other tools, Selection and Subselection Tool, changes the perimeter of the text field. I know it can be frustrating when a text is scaled unexpectedly. You can see if the textfield has been scale/skewed even if there is nothing in it during author-time by going to the Transform window (CTRL+T).
              • 4. Re: Font size changes when textfield height changes
                woodtah Level 1
                Thanks for the info -- I was not aware of that. I assume this would also be true when modifying the height and width properties via actionscript?