开发者

Create Vertical-Tabbed OS X Cocoa View

开发者 https://www.devze.com 2023-04-02 12:30 出处:网络
I\'m interested in having a application with a layout similar to the tabbed operation of iChat (see image below).

I'm interested in having a application with a layout similar to the tabbed operation of iChat (see image below).

Create Vertical-Tabbed OS X Cocoa View

Does anyone know of any pre-built constructs that allow this sort of UI? I know there is NSTabView for tabs across the top of the application, but what about vertical orientation? For my purposes, the view associated with the tabs doesn't necessarily need to scroll. In fact it has nothing to do with chatting an开发者_Go百科yway, I simply like this layout.

Thanks.


The view on the left is an NSTableView with source list-style highlighting:

tableView.selectionHighlightStyle = NSTableViewSelectionHighlightStyleSourceList;

You can use a tabless NSTabView for the right part, but you could just as well change the content of the displayed views or swap the views entirely. That depends on how many “tabs” there’ll be and how the content displayed on the right side will be different.

0

精彩评论

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