Hi, A project I am working on needs a branding glyph drawn inside an NSTableView(lower right corner), currently I am doing it like so...
- (void)highlightSelectionInClipRect:(NSRect)rect {
[_image drawAtPoint:NSMakePoint(rect.size.width - [_image size].width, rect.size.height - [_image size].height) fromRect:NSMakeRect(rect.origin.x, rect.origin.y,[_image size].width,[_image size].height) operation:NSCompositeSourceOver fraction:1.0];
//I draw a special highlight here etc...
So far this works out ok, but I am just looking for a few opinions, is this the correct place for this action, and does my drawing code look correct?
Thanks! ~J |