textViewDidChangeSelection
textViewDidChangeSelection
- Subject: textViewDidChangeSelection
- From: Jeremy Dronfield <email@hidden>
- Date: Wed, 19 Jun 2002 18:28:40 +0100
I've got the following method which enables a button when text in a
TextView is selected:
- (void)textViewDidChangeSelection:(NSNotification *)aNotification
{
[[self markButton] setEnabled:YES];
}
It works, but I really want to know how to make it conditional, so that
if the text is deselected, markButton is disabled again. I've messed
about with various if's using selectedRange, but can't get anything to
work. The problem seems to be that I don't know how to access
selectedRange's length.
- Jeremy
_______________________________________________
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.