Re: Up arrow in NSTextView
Re: Up arrow in NSTextView
- Subject: Re: Up arrow in NSTextView
- From: Oliver Cameron <email@hidden>
- Date: Tue, 29 Mar 2005 22:30:31 +0100
This is what I do, replace the unicode char number for the up key:
- (void)keyDown:(NSEvent *)theEvent
{
unichar unicodeChar;
NSString *characters;
characters = [theEvent characters];
unicodeChar = [characters characterAtIndex:0];
if (unicodeChar == 0x0009)
{
Do whatever happens on up key.
}
}
This is in a NSTextView subclass.
Thanks,
On 29 Mar 2005, at 22:23, Adam wrote:
What is the easiest way for me to detect that the user has pressed a
specific key in an NSTextView?
Adam
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden