flash? (HI UNFIT...)
- Started
- Last post
- 16 Responses
- jpolk
is there any thing you can do to fix the funky word wrapping issue in flash MX?
i,e.: when i am displaying text from XML i occasionally get a blank space as the first character on a line. rather annoying to pick through a 2200 node document and add 'space, space, space'.
- jpolk0
nah?
- jpolk0
space, space, space...
- jox0
maybe it's personal?
- 4cY0
maybe unfit is unfit to answer now..
- jpolk0
thought so...
- kpl0
if I knew how to use substr() from the top of my head...I'd tell you the syntax...
but can you set up a while loop where while the first character of a string was a space (or whatever character), then have the string equal the 2nd to last character of the string?
ie
while (string.substr(0,1) == " ") {
string = string.substr(1,string._length);
}or something like that.
- kpl0
i meant...
"... then have the string equal the 2nd character to last character of the string?..in effect including the entire string except the first character"
- jpolk0
good idea, but the problems are occurring multiple times within the same string at line break. i'm not sure how to detect a carriage return.
- unfittoprint0
olá.
not quite following you, but it may have something to do with XML's encoding [and special characters]. Try changing it to 'utf-8'.
- unfittoprint0
myXML.ignoreWhite = true; [?]
- jpolk0
yeah, i'm pretty sure my ducks are in a row, i think it's an issue with the textfield object. i see this issue in dynamic flash sites from time to time. just wondering if there is a quick fix. guess it's back to forcing line breaks with spaces...
- jpolk0
http://chattyfig.figleaf.com/ezm…
solves this problem, just posting because it was making me crazy...
- unfittoprint0
You had unwanted empty spaces in the beginning of the textfield?
- jpolk0
yeah, apparently it's a bug with the flash player, esp. prominent when pulling text from XML.
- unfittoprint0
You must be talking about an empty line in the beginning.....
I usually reset the textfiled with something like
myText.htmlText="";
before populating it....
- JazX0
help out a PBurgh boy unfit hehehee ;)