The cocoa method seems to only work if the input method was previously enabled by the user.

For the carbon method, do I get the current one with TISCopyCurrentKeyboardLayoutInputSource, set the new one (Kotoeri Katakana) with TISSetInputMethodKeyboardLayoutOverride, then re-set the old one with TISCopyCurrentKeyboardLayoutInputSource? (following first responder status of the text field) If thats the case, how would I get a reference to the new one? The only function that I noticed is TISCreateInputSourceList, but what properties would I pass to it?
Sorry for all the questions... I'm a bit unfamiliar with Carbon.

On Apr 8, 2008, at 12:20 PM, Aki Inoue wrote:

Right now, there is no way to specify Japanese "Hiragana" just using Cocoa API.

Starting from Leopard, you can use -[NSTextFieldCell setAllowedInputSourceLocales:] with an array containing @"ja" (the Japanese locale) to narrow it to Japanese input modes.

Or, also from Leopard, you can use TextInputSource API in Carbon framework to fine control the input source.

Aki

On 2008/04/08, at 11:59, Dimitri Bouniol wrote:

I would like to force a text input method, such as the Japanese hiragana input, onto a NSTextField programatically. How would I go about doing this?


--
定魅刀利
Dimitri Bouniol
[EMAIL PROTECTED]
http://web.mac.com/dimitri008/



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [EMAIL PROTECTED]

Reply via email to