2 Replies Latest reply on Feb 5, 2010 3:51 AM by Francisc

    Yet another htmlText problem!

    andrewthorp Level 1

      As I know htmlText has it's plethora of problems, I have been able to work around a few of them. However, after trying many different things, I cannot seem to fix this one:


      <mx:Text htmlText="{_articleText}" width="100%" fontSize="12" color="0x282828" />


      In the script, I set _articleText = "<img src='"+dataProvider.imageURL(_model.account.id)+"' align='"+dataProvider.imageAlignment+"' />"+dataProvider.body;


      This is fine, the image aligns to the left or right and is loaded in correctly, but I notice the element cuts off 3-4 lines of text from the bottom. It just looks like it disappeared, but if you highlight and scroll down you can see that the text is there, but the element is miscalculating the height.


      Apparently it is due to the measure method of text not taking into account leading? How can I work around this?