I have the following code in an NSCollectionView subclass:
-(void)drawRect:(NSRect)rect {
if(!NSEqualRects(highlightBox,NSZeroRect)) {
[[NSColor colorWithCalibratedRed:1.0f green:0.2f blue:0.2f alpha:1.0f] set];
NSRectFillUsingOperation(NSInsetRect(tempHighlightBox, -1.0, -1.0),NSCompositeSourceOver);
[[NSColor colorWithCalibratedRed:0.2f green:0.2f blue:1.0f alpha:0.5f] set];
NSRectFillUsingOperation(tempHighlightBox,NSCompositeSourceOver);
}
}
The NSRect is drawn ok, but it is behind any of the NSCollectionViews subviews and I would like it to be over the top. Is this possible?