开发者

How can i create a transparent and non rectangular NSWindow with Cocoa?

开发者 https://www.devze.com 2023-01-12 22:40 出处:网络
I want to create a windows style error popup for my Cocoa application like this one Is there any 开发者_如何学JAVAtutorial how to do this? Or can somebody give me at least the names of a few API fun

I want to create a windows style error popup for my Cocoa application like this one

How can i create a transparent and non rectangular NSWindow with Cocoa?

Is there any 开发者_如何学JAVAtutorial how to do this? Or can somebody give me at least the names of a few API functions that i need to check out.


Apple has an example: Round Transparent Window


Take a look at MAAttachedWindow. You can configure its background and border to match.


As of 10.7, you can do this with NSPopover.

I'm not sure whether you can make one transparent, but the default appearance is consistent with how popovers are expected to look on the Mac.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号