KeyDown event
KeyDown event
- Subject: KeyDown event
- From: Joe Chan <email@hidden>
- Date: Tue, 23 Oct 2001 21:20:58 -0400
I would like to process individual key down event in my window.
Looking at NSResponder, I overrode keyDown: of my window
controller. The question I have about the NSEvent object is the
message characters. It returns an NSString, which means that it
can potentially return more than one characters. My question is:
if I just want to find out which key the user pressed (with the
appropriate key mapping already applied), is [theEvent
characters] a reliable way to accomplish that? In other words, I
can assume that if the key down event is not repeating, the
event object will always return one character, which corresponds
to the key the user pressed?
-----------
Joe Chan
email@hidden
http://www.firstian.com