Re: text Encoding with Write to file
Re: text Encoding with Write to file
- Subject: Re: text Encoding with Write to file
- From: Christopher Nebel <email@hidden>
- Date: Mon, 9 Jan 2006 12:47:41 -0800
On Jan 9, 2006, at 2:18 AM, Bastiaan Boertien wrote:
Well the problem is that I want to write a file with MacRoman text
encoding. I found a lot on the internet and it doesn't work
They said that write [...] as string will be MacRoman text encoding
but this doesn't work.
Well, maybe. Technically, "as string" doesn't force MacRoman, it
forces your "primary encoding", which is dictated by the first
language in your International preferences. For most people on this
list, that's English (or possibly another Western European language,
such as French, German, or Dutch), and therefore the primary encoding
is MacRoman. For a typical Japanese user, it would be Japanese and
hence MacJapanese.
How are you determining that the file isn't MacRoman? file(1) is
trivial to fool, since it mostly relies on the first few bytes of the
file. Similarly, I wouldn't trust any BSD tool to know the first
thing about MacRoman, and that includes pico. Try just opening it in
TextEdit, ask for MacRoman, and see what you get.
--Chris Nebel
AppleScript and Automator Engineering
_______________________________________________
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