• 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: Custom NSTextField & keyDown:
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Custom NSTextField & keyDown:


  • Subject: Re: Custom NSTextField & keyDown:
  • From: Ryan McGann <email@hidden>
  • Date: Mon, 23 Sep 2002 19:05:09 -0700

On Monday, September 23, 2002, at 12:16 PM, Douglas Davidson wrote:

On Saturday, September 21, 2002, at 08:26 PM, Ryan McGann wrote:

- I need to convert the key code into a character. In Carbon I can call KeyTranslate. What's the similar functionality in Cocoa?

I also meant to say--look at the NSEvent documentation for this.

If you're referring to charactersIgnoringModifiers, it should be noted that this does not ignore the shift key. I don't want to display command-shift-#, I want to display command-shift-3.

But the bigger issue is that my -keyDown: method is never called. And even if I change it to keyUp:, I still don't get called if the user is holding down the command key, because Cocoa is trying to perform key binding. I would need to fix that before anything else. In Carbon, I can simply install a raw KeyDown event handler, which is called before any key binding is done.

Thanks,
Ryan
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.

References: 
 >Re: Custom NSTextField & keyDown: (From: Douglas Davidson <email@hidden>)

  • Prev by Date: Re: [Q] Calling isEmpty on an NSRange?
  • Next by Date: Re: Custom NSTextField & keyDown:
  • Previous by thread: Re: Custom NSTextField & keyDown:
  • Next by thread: awakeFromNib not initialising interface objects
  • Index(es):
    • Date
    • Thread