问题
How could I make an NSWindow
's title bar look like that of the Mac App Store or of the app Feeder where it's height is increased and other controls are show in it.
To see what I mean just check out the website for the Mac App Store : http://www.apple.com/mac/app-store/.
Is it a custom NSWindow
or is it a completely borderless window with an NSView
made to look like the title bar?
回答1:
https://github.com/indragiek/INAppStoreWindow
Title bar and traffic light customization for NSWindow
INAppStoreWindow
is an NSWindow subclass that was originally developed to mimic the appearance of the main window in the Mac App Store application introduced in OS X 10.6.6.The MAS application has since transitioned away from this design, but
INAppStoreWindow
is still being actively developed to provide extensive additional customization options forNSWindow
title bars...
回答2:
For iTunes (v9.x) Apple used no toolbar, but custom aligned icons and controls in the top bar, to achieve a similar effect. (see link below)
The window looks like a "textured & unified title and toolbar" window to me. (or a slight variant of such)
To reposition the traffic light buttons follow my answer to this question.
However, as Dave DeLong already (similarly) commented: "The UI is terrible. Please don't even think about it."
回答3:
You can also take a look at http://orestis.gr/blog/2007/09/24/messing-with-windows/ . This uses some undocumented stuff, though, so it won't actually get approved FOR the App Store.
来源:https://stackoverflow.com/questions/4586721/nswindow-mac-app-store-like-title-bar