Re: Unicode Codepoints
Re: Unicode Codepoints
- Subject: Re: Unicode Codepoints
- From: Neil Faiman <email@hidden>
- Date: Fri, 18 Mar 2005 07:19:35 -0500
On Mar 18, 2005, at 6:47 AM, Rob Stott wrote:
...I want to be able to do something like this...
tell application "TextEdit"
make new document at beginning
tell front document
set character 1 to Unicode codepoint "\U000048"
end tell
end tell
Obviously, I made up the 'Unicode codepoint' bit of the second example.
I've installed Unicode OSAX, but have failed to get any kind of result out of it whatsoever. Does anyone have any suggestions?
Matt Neuburg's _Definitive Guide_ is rather discouraging: "You can't even type a Unicode text literal in AppleScript. Well, you can, but AppleScript will render it as MacRoman when you compile the script, so any characters outside the range of MacRoman are lost." And he goes on to give a variety of rather unsatisfactory solutions, of which the most elegant (to my eyes, anyway) is this one:
set p to "use utf8;\n"
set p to p & "print chr(0x017e);"
set s to do shell script "perl -e " & quoted form of p
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden