On Sat, 24 Mar 2007 08:59:29 -0700,
Edward de Jong (email@hidden) wrote:
>In the menu bar there is a kind of an input mode selector, where you
>pick "arabic", "arabic qwerty", "hawaiian", and I want to get this
>region code or whatever the number is that corresponds to each of the
>input methods, so that my program can turn text entry right to left
>when Hebrew is selected.
Even in the old days of classic Mac OS, applications would typically
pick a default primary line direction based on the value returned by
GetSysDirection(), not based on the direction of the selected script
(GetScriptVariable(GetScriptManagerVariable(smKeyScript), smScriptRight)).
You don't want the primary line direction to suddenly switch from L2R
to R2L just because the user selects Hebrew from the input menu in
order to insert a Hebrew word into an English paragraph.
Now script codes are a thing of the past, and even GetSysDirection()
was deprecated in Tiger, with no suggested replacement.
My guess is that your best option is to provide some UI, probably
in the form of a Writing Direction submenu, to set the primary line
direction of the selected paragraph(s), as TextEdit.app does.
-- marco
--
It's not the data universe only, it's human conversation.
They want to turn it into a one-way flow that they have entirely
monetized. I look at the collective human mind as a kind of
ecosystem. They want to clear cut it. They want to go into the
rainforest of human thought and mow the thing down.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Carbon-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/carbon-dev/email@hidden
This email sent to email@hidden