I have a cell-based NSTableView with a text cell in a particular column. I want to provide a custom field editor so that I can do auto completion without the user pressing F5.
@implementation AutoCompleteFieldEditorTextView
-(id)init
{
self = [super init];
if (self)
{
self.focusRingType = NSFocusRingTypeDefault;
self.fieldEditor = YES;
}
return self;
}
@end
This works ok except the focus ring does not exist. Even if I add:
-(void)drawFocusRingMask
{
NSRectFill([self bounds]);
}
-(NSRect)focusRingMaskBounds
{
return [self bounds];
}
it still does not work. How can I get the exact focus ring that appears with the default NSTextView used as a field editor in an NSTableView?