Re: [Flashcoders] mdash in htmlText

2008-01-15 Thread Juan Pablo Califano
Well, I've made a class to do just that, might be handy to have it. You can find both AS 2.0 and AS 3.0 versions here: http://pastebin.be/8273 (AS 3.0) http://pastebin.be/8274 (AS 2.0) Just add any entity you need to the charMap. Use example: var original:String = "día sésamo ñoño Ño"; var

Re: [Flashcoders] mdash in htmlText

2008-01-15 Thread Juan Pablo Califano
Perhaps this is not the most optimal (performance-wise), but if the flash html renderer doesn't natively support most of the html entities, you can make your own (I don't know of any class that already does it, but it might already been written). It shouldn't be hard. You can find the a list with

RE: [Flashcoders] mdash in htmlText

2008-01-15 Thread Rob Emenecker
y the easiest way to do it. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andrew Sinning Sent: Sunday, January 13, 2008 10:23 PM To: Flash Coders List Subject: Re: [Flashcoders] mdash in htmlText Thanks Helmut. With your lead I was able to come u

Re: [Flashcoders] mdash in htmlText

2008-01-13 Thread Andrew Sinning
Thanks Helmut. With your lead I was able to come up with the following. (There's probably a better way to do a replaceAll, but using slit.join is least amount of code that I know of.) function htmlAmpCharsToFlashHtmlAmpChars(str:String):String { str = str.split(" ").join(" "); str = s

Re: [Flashcoders] mdash in htmlText

2008-01-13 Thread Helmut Granda
mdash = — theTextField.htmlText = blahblahblah — blahblah; of course you can also bring the text from XML or such On 1/12/08, Andrew Sinning <[EMAIL PROTECTED]> wrote: > > I'm running CS3 with AS2. > > I'm loading in some html text into a TextField with html set to true. > It looks like   i

RE: [Flashcoders] mdash in htmlText

2008-01-13 Thread Rob Emenecker
w and post a follow-up. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Andrew Sinning Sent: Sunday, January 13, 2008 9:58 AM To: Flash Coders List Subject: Re: [Flashcoders] mdash in htmlText It would be fantastic if you could share. Were you using AS3

Re: [Flashcoders] mdash in htmlText

2008-01-13 Thread Andrew Sinning
It would be fantastic if you could share. Were you using AS3? If not, what did you do for regex? I tried to figure out the as2lib project's implementation of regex but couldn't get a simple replaceAll to work Thanks! Rob Emenecker wrote: Hi Andrew, I don't know of a class that will he

RE: [Flashcoders] mdash in htmlText

2008-01-12 Thread Rob Emenecker
Hi Andrew, I don't know of a class that will help with this. Extended characters need to be Unicode encoded in the HTML stream for Flash to properly display them. I've had to do exactly what you probably don't want to do... that is, scrub them out. I had a project that wrapped up late summer las