A Flash Developer Resource Site

Results 1 to 3 of 3

Thread: Dynamic scrolling text box resize

  1. #1
    Senior Member
    Join Date
    Sep 2004
    Location
    West Mids, UK
    Posts
    101

    Dynamic scrolling text box resize

    Hey guys, I have been working on a scrolling "news ticker" for a friend of mine now for a while, it basicly pays a 20 min flash video file looped and he can edit a text file which will then show the contents on a news ticker system for anouncements.

    Now I have the flash video looping, I even have the "marquee" efect working (the box moving across the screen) and even have the contents of the file in the text box.

    So whats the problem> simple TEXT WRAP

    the way the box moves along the screen is it checks the top right corner of the textbox to see if it is below 0, if it is then it moves it back and resets again. Now the problem I am having is that the text isn't fitting in the text box its missing 90% of it because of the textbox having a set width.

    In short I need to work out how to change the width of the textbox so that all the text is in there. I have to use a single line (one of the requirements) so multiline is out of the question and so is scrolling the textbox as its designed to move across the screen as a news ticker but I cant get the text to fit in the box, any ideas on how to do this???

    thanks

  2. #2
    Senior Member
    Join Date
    Sep 2004
    Location
    West Mids, UK
    Posts
    101
    So far I have tried several attempts to do this and all have failed

    the only way I can think of is to count the number of characters in the variable and do some maths to work out how long the textbox should be, problem is this wont work as not all characters of the same font are the same size

  3. #3
    Senior Member
    Join Date
    Sep 2004
    Location
    West Mids, UK
    Posts
    101
    *bump*

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