• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Changing FirstResponder with Inputmethod
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Changing FirstResponder with Inputmethod


  • Subject: Re: Changing FirstResponder with Inputmethod
  • From: imai asato <email@hidden>
  • Date: Fri, 15 Jan 2010 07:48:12 +0900

I found EXC_BAD_ACCESS error occurs when garbage collection is on only.
But when when garbage collection is off, first letter is not send to NSTextField if InputMethod is on.
For example, when typing  '1' '2' '3' three keys when NSTextField is not first responder.
If InputMethod is off, NSTextField shows "123".
If InputMethod is on, NSTextField show "23".

Is this bug of OS?
I'm using 10.6.2.


On 2010/01/13, at 10:39, imai asato wrote:

> Hello,
>
> I have NSTextField and some views(NSTableView etc).
> I want interrupt keydown event when NSTextField is not first responder to input the key to NSTextField.
> I wrote keyDown: method of my NSWindowController class like below.
>
> - (void)keyDown:(NSEvent *)event
> {
> 	// IBOutlet NSTextField*  myInput;
>
> 	if ([[self window] firstResponder] != myInput) {
> 		[[self window] makeFirstResponder:myInput];	// to change keyView
> 		[[self window] sendEvent:event];				// to process keydown event
> 	}
> }
>
> This works well when keyboard layout is US.
> But when Japanese inputmethod is on, EXC_BAD_ACCESS on CopyRgn of GetPortVisionRegion of CTextensionDisplay::Focus… is occur.
>
> Does anyone have any idea?
>
>
> --
> imai asato
>
>
>
>
> _______________________________________________
>
> Cocoa-dev mailing list (email@hidden)
>
> 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:
>
> This email sent to email@hidden

_______________________________________________

Cocoa-dev mailing list (email@hidden)

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:

This email sent to email@hidden

References: 
 >Changing FirstResponder with Inputmethod (From: imai asato <email@hidden>)

  • Prev by Date: Re: NSDocument
  • Next by Date: Re: NSDocument
  • Previous by thread: Changing FirstResponder with Inputmethod
  • Next by thread: Trying to create an alias file by using the new NSURL methods available with Mac OS X 10.6 !
  • Index(es):
    • Date
    • Thread