Skip to content

Instantly share code, notes, and snippets.

@summic
Created November 18, 2012 15:31
Show Gist options
  • Save summic/4105830 to your computer and use it in GitHub Desktop.
Save summic/4105830 to your computer and use it in GitHub Desktop.
Create Borderless Transparent Window:
- (id) initWithContentRect: (NSRect) contentRect
styleMask: (unsigned int) aStyle
backing: (NSBackingStoreType) bufferingType
defer: (BOOL) flag
{
if (![super initWithContentRect: contentRect
styleMask: NSBorderlessWindowMask
backing: bufferingType
defer: flag]){
return nil;
}
[self setBackgroundColor: [NSColor clearColor]];
[self setOpaque:NO];
return self;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment