问题描述:

How do I manually draw those toolbar buttons that act as tabs? I mean the control in the top of this window (see below). I think technically they are radiobuttons placed on a toolbar, or at least they evolved from that.

Is there any HITheme* API to draw them? Or do I have to use CoreUI? I tried CUIDraw with kCUIWidgetButtonSegmentedSCurve, but that just gives an ordinary segmented toolbar button (like on top of a finder window). What I'm looking for is the "settings tab" version:

网友答案:

Use NSToolbar + set of NSToolbarItems with "selectable" property set. This will do the trick.

相关阅读:
Top