[Extendflash] Using the JSFL FLFile.write and UTF8

Tomas van der Haase tvander at macromedia.com
Sat Aug 6 13:21:04 PDT 2005


Hello:

U make a great point. I would add that it would be best to comply with 
the standard for UTF8 as a matter of course. I have filed a bug report 
on this & sent it to the review board for exposition. Unfortunately 
we're a bit late in the cycle.


Tomas van der Haäse
Flash 8 Quality Assurance Engineer
Macromedia, Inc.



On Aug 5, 2005, at 1:46 PM, Morten Barklund Shockwaved wrote:

>> u r correct, this is the current behavior.
>> just out of curiosity. what situation r u running into which requires 
>> the BOM [byte order marker] at the start of the UTF8 file?
>
> I've made a little JSFL script, which creates a lot (126 actually) of 
> actionscript2 class files for me. This includes some generel warning 
> messages written in danish including special characters. This 
> generated a UTF8-encoded file (or at least the characters were in 
> UTF8), but without the BOM. Thus when read into my flash production, 
> the files were included as if they where written in Latin1 - and my 
> characters became fubar - or at least beyond the client's recognition 
> :)
>
> I've made a little workaround using a function, that converts the six 
> special characters, that my use is limited to, into their 
> utf8-urlencoded entities. That is, what the escape function would 
> produce, if working on UTF8 characters. But the escape function cannot 
> be used, as the characters in the JSFL script is actualle evaluated as 
> Latin1. Then in my script, the files including these auto-generated 
> classes simply unescape's the strings before use. This sounds 
> complicated, but actually the unescape function is only applied in one 
> place - as all warning messages from these files go through here.
>
> But why JSFL doesn't use UTF8 and unicode is beyond me!
>
> -- 
> Morten Barklund - Information Architect - Shockwaved ApS
> Larsbjoernsstraede 8 - DK-1454 Copenhagen K, Denmark
> Phone: +45 7027 2227 - Fax: +45 3369 1174
> _______________________________________________
> Extendflash mailing list
> Extendflash at flashguru.co.uk
> http://lists.flashguru.co.uk/mailman/listinfo/extendflash
>



More information about the Extendflash mailing list