开发者

Cocoa / Interface Builder: What do I need to subclass to replicate this window?

开发者 https://www.devze.com 2023-01-25 01:51 出处:网络
I\'m guessing it is using a custom NSWindow, NSTextField, NSSecureTextField, NSButton? I don\'t开发者_StackOverflow necessarily want to replicate it, I would just like to know what would be involved i

I'm guessing it is using a custom NSWindow, NSTextField, NSSecureTextField, NSButton? I don't开发者_StackOverflow necessarily want to replicate it, I would just like to know what would be involved in customizing my app's UI to this level.

Cocoa / Interface Builder: What do I need to subclass to replicate this window?


The window itself could be a HUD-style panel, which you can get in IB without subclassing anything. It looks like there's a bit of custom background to it, unless it's just faintly showing something behind it; if it is a custom background, a custom view as the content view could do that job.

The separator could be an image view or a custom view.

The static text fields can be done without subclassing. Just change the text color.

The editable text fields, both the regular one and the secure one, you would need to subclass. I have no idea how you would do that.

The follow-link button is a mix of custom drawing and a standard image. Start with the NSImageNameFollowLinkFreestandingTemplate image; draw that, then fill an empty path with white using the source-in blend mode.

The other two buttons are customized, probably using custom cells in order to override the background without overriding the text drawing.

0

精彩评论

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