i had this problem a while ago. the text would be rendred exactly the same on all platforms buth the numbers returned from textExtend varied depending on os, browser, i don't know what else. with a tendency to cut off lines/letters on mac. i came up with the following: took a largish block of text of length (L), set the field width to the one i needed and counted how many rows it would take in a static field (R). now C = L/R is an approximation of how many letters fits in a row. you can measure H the height of a single row in pixels on a static field too. then to display your string textString you need field of height=(Math.ceil(textString/C)+1)*H i add one because it's approximate and i prefer to have some extra space than cut off text. it works quite weel for strings tha occupy more than 5 rows. you can easily adapt is to measuring width of a single row of text too. cheers, michal
I've noticed a post about this in the archives, but it was described as a Mac issue and I'm getting it on a PC. I'm trying to use TextFormat.getTextExtent() to do some image calculations, but I'm getting enormous values. I suspect it's because my text includes newline characters, but that's just a guess. The docs say the function is deprecated, but the liveDocs emphatically deny this. Anyone got any suggestions?
_______________________________________________ Flashcoders@chattyfig.figleaf.com To change your subscription options or search the archive: http://chattyfig.figleaf.com/mailman/listinfo/flashcoders Brought to you by Fig Leaf Software Premier Authorized Adobe Consulting and Training http://www.figleaf.com http://training.figleaf.com