2 Replies Latest reply on Jun 21, 2007 8:56 AM by LH

    Wordwrap problem on dynamically generated text

      We are dynamically generating a text box with the content coming from XML files. The XML files have some href code in to handle a glossary function. This all works fine most of the time, but sometimes when you have two glossary words near each other and you move the cursor over them, flash adjusts the word wrapping on the text box very slightly and and you get a word or two jumping from one line to the next.

      Code for text box looks like this...

      function createBodyText() {
      var depth = _level0.holder_mc.getNextHighestDepth();
      Body_txt = _level0.holder_mc.createTextField('Body_txt', depth, 20, 173, 400, 550);
      _level0.holder_mc.Body_txt.html = true
      _level0.holder_mc.Body_txt.condenseWhite = true
      _level0.holder_mc.Body_txt.multiline = true
      _level0.holder_mc.Body_txt.wordWrap = true
      _level0.holder_mc.Body_txt.antiAliasType = true
      _level0.holder_mc.Body_txt.selectable = false
      _level0.holder_mc.Body_txt.embedFonts = true

      Code in XML file which seems to sometimes causes wordwrap to redraw...

      The vital role of the <a color="#0099FF" href='asfunction:setGlossary,50' >neuraminidase</a> enzyme is to break this bond and...

      Any ideas anyone??? stuck on this for weeks and no luck.