[Solved] Re: NSTextField: how to make the text cursor blink?
[Solved] Re: NSTextField: how to make the text cursor blink?
- Subject: [Solved] Re: NSTextField: how to make the text cursor blink?
- From: Stéphane Sudre <email@hidden>
- Date: Fri, 5 Dec 2003 22:06:02 +0100
Using a NSFormatter is solving this.
On jeudi, dicembre 4, 2003, at 11:27 PM, Stiphane Sudre wrote:
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.