Re: Words of Bug in Leopard (Japanese environment)
Re: Words of Bug in Leopard (Japanese environment)
- Subject: Re: Words of Bug in Leopard (Japanese environment)
- From: Christopher Nebel <email@hidden>
- Date: Mon, 11 Aug 2008 12:04:04 -0700
Well, I encourage you to file bugs. Word breaking in Japanese is, by
definition, sort of hard, since it doesn't use any sort of word
separators. (Though I have no idea why it got that one wrong, since
as far as I can tell "一番高" isn't a real word.) The word break
behavior isn't specific to AppleScript -- as I said before, it relies
on the system utilities for word breaking, which rely on data that
comes from the Unicode specification. In other words, it may be
wrong, but at least it's consistent -- try using option-arrow to move
by words through text, and you'll see what I mean.
--Chris Nebel
AppleScript Engineering
On Aug 8, 2008, at 6:56 PM, Takaaki Naganoya wrote:
It is a nice Joke! I am laughing out loud.
AppleScript's word breaking ability for *natural* language ?
It is useless for parsing with "natural language".
I don't expect natural language parsing ability to AppleScript.
Japanese word breaking?
<AppleScript>
set a to "富士山は日本で一番高い山です。"
set b to words of a
</AppleScript>
--> {"富士山", "は", "日本", "で",
"一番高", "い", "山", "です"}
It is crazy and useless *word* breaking. We thought word breaking
ablitity in AppleScript is a kind of joke.
On 2008/08/06, at 15:20, Christopher Nebel wrote:
Basically, don't use "word" elements to process anything other than
natural language text. In your case, you probably want text items
breaking on ":". Alternatively, you could set your word break
preference (System Preferences > International > Language > Word
break) to "English (United States, Computer)", which always treats
":" as a word break, but that would probably do horrible things to
your Japanese word breaking.
--
Takaaki Naganoya
Piyomaru Software
http://piyo.piyocast.com
email@hidden
PiyoCast Web (Podcasting with Music!)
http://www.piyocast.com
Free AppleScript Library "AS Hole"
http://www.piyocast.com/as/
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (applescript-
email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users
This email sent to email@hidden