NSTextField: how to make the text cursor blink?
NSTextField: how to make the text cursor blink?
- Subject: NSTextField: how to make the text cursor blink?
- From: Stéphane Sudre <email@hidden>
- Date: Thu, 4 Dec 2003 23:27:14 +0100
I built a subclass of NSTextField and replace the drawRect method with
the following one:
- (void) drawRect:(NSRect) aRect
{
static NSFileManager * sFileManager=nil;
if (sFileManager==nil)
{
sFileManager=[NSFileManager defaultManager];
}
if ([sFileManager fileExistsAtPath:[self stringValue]]==YES)
{
[_cell setTextColor:[NSColor blackColor]];
}
else
{
[_cell setTextColor:[NSColor redColor]];
}
[super drawRect:aRect];
}
The issue is that, now, the text cursor is no more blinking.
Is there any other way to change the text color without disturbing the
text cursor?
_______________________________________________
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.