A Flash Developer Resource Site

Results 1 to 5 of 5

Thread: possible to concatenate a word with DIFFERENT font in dynamic text field?

  1. #1
    Junior Member
    Join Date
    Aug 2009
    Posts
    8

    possible to concatenate a word with DIFFERENT font in dynamic text field?

    Hello.

    I have a submit button that I'm pulling in from XML.

    It needs to be XML because it is translated.

    Therefore... the length is varying depending on the language.

    I simply want to add an arrow to the end of the word using Webdings #4 (it looks like a solid arrow, not like > but solid)...

    Is this the best way to do this? What are my options?

  2. #2
    Senior Member cancerinform's Avatar
    Join Date
    Mar 2002
    Location
    press the picture...
    Posts
    13,448
    Why don't you create a second textfield with the second font and place it behind the first one?
    - The right of the People to create Flash movies shall not be infringed. -

  3. #3
    Junior Member
    Join Date
    Aug 2009
    Posts
    8
    Well as I just stated the length of the first text field is dynamic. For english it might be just "Submit" for spanish, "presentar" or chinese "提交"..

    If I just do it that way the arrow will appear at the far end of the text field (not at the end of the word for shorter translations).

    It looks like crap when you have an arrow floating around all on its own.

    Maybe I am not understanding - are you saying that putting a text field at the end of the other one it will automatically adjust its position right next to the end of the word. If that is possible please share!
    Last edited by sethwb; 09-20-2010 at 09:01 AM.

  4. #4
    Senior Member cancerinform's Avatar
    Join Date
    Mar 2002
    Location
    press the picture...
    Posts
    13,448
    You cannot have more than one font in a textfield simultanously. You can only change the font of a textfield dynamically. If you have a textfield with a fixed width and adjust the text to the right end, the distance between the end of a word and the arrow in the next textfield will always be the same.

    If you don't want that and stay with autosize of a textfield, then you can measure the width of the textfield and adding this to the x-position. Then you can adjust the second textfield accordingly every time the text changes.
    - The right of the People to create Flash movies shall not be infringed. -

  5. #5
    Junior Member
    Join Date
    Aug 2009
    Posts
    8
    Ok I'll give it a shot. Thanks C

    seth

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center