Re: Transparent content view of NSWindow clicks through
Re: Transparent content view of NSWindow clicks through
- Subject: Re: Transparent content view of NSWindow clicks through
- From: Brett Powley <email@hidden>
- Date: Sun, 15 Jun 2008 08:32:22 +1000
The things I found you have to do to get this working are, for your
subclass of NSWindow are:
[self setIgnoresMouseEvents:NO];
[self setBackgroundColor:[NSColor clearColor]];
[self setOpaque:NO];
and also override
-(BOOL) canBecomeKeyWindow
to return YES
Cheers,
Brett
On 15/06/2008, at 6:05 AM, John Joyce wrote:
I'm toying with using a transparent content view of an NSWindow.
Of course, when you get the background totally transparent, you
click in the rect, it clicks through to activate whatever is behind
the window. Does anybody know a way to have that much transparency
and not click through?
I'm sure it's possible to render a background image that is whatever
is behind the window, but that might eat up more processing than
would be practical.
(yes, I have gone over the sample code, RoundTransparentWindow )
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
@process.com.au
This email sent to email@hidden
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden