I want to replace RBSplitView with NSSplitView in my existing project. The application is now leopard only and I would like to replace RBSplitView with the new NSSplitView shipped with Leopard.
However, I’m missing RBSplitView‘s handy methods expand and collapse in NSSplitView. How can I expand and collapse parts of NSSplitView programmatically?
I just got programmatic expanding and collapsing of
NSSplitViewto work. I’ve also configured myNSSplitViewto expand/collapse a subview whenever the divider is double-clicked, so I wanted this to play nice with that feature (and it seems to). This is what I did:(in this example,
splitViewis theNSSplitViewitself,splitViewSubViewLeftis the subview I wish to expand/collapse andlastSplitViewSubViewLeftWidthis an instance variable of typeCGFloat.)