SHELL text encoding OS X?
Peter W A Wood
peterwawood at gmail.com
Sat Jul 26 10:32:42 EDT 2014
As I understand, the OS X shell assumes text is UTF-8 encoded whereas Livecode on OS X assumes text is MacRoman encoded. (I'm guessing you're running this on a Mac).
So you need to convert the UTF-8 to MacRoman. With LiveCode 6.6, I believe that involves converting first to "unicode" (actually UTF-16) and then to MacRoman. I took a quick look at Devin Asay's Unicode tutorial - http://livecode.byu.edu/unicode/unicodeInRev.php
It seems you need to do something like this, assuming you have a "spare" field hanging around:
set the unicodetext of field "temp" to uniencode(tResultFromMDFind,"UTF8")
get the unicodetext of field "temp"
put unidecode(it,"English") into tWhatIWanted
I realise that the English seems a bit odd for German but I think it's a LiveCode synonym for what Unicode calls "Roman" languages.
Hope this helps.
On 26 Jul 2014, at 21:47, Klaus major-k <klaus at major-k.de> wrote:
> Hi Warren,
> Am 26.07.2014 um 15:43 schrieb Warren Samples <warren at warrensweb.us>:
>> On 07/26/2014 08:05 AM, Klaus major-k wrote:
>>> thank you, but my question was:
>>>>>>> Anyway, what can I do in LC 6.6.2?
>> You also wrote this:
> Yes, "also"!
>> "This even happens with LC 7dp7, but shouldn't right?"
>> so it seemed you might be interested in how it's supposed to work there.
> OK, let's agree that I want to know both solutions, one for LC 7.x, thank you for that,
> and one solution for LC 6.6.2 :-)
> Klaus Major
> klaus at major-k.de
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
More information about the Use-livecode