Take a look at the Cocoa documentation for NSSplitViewDelegate, specifically the methods related to constraining the split position.
Hi,
I'm currently working on a simple functionality of my app that allows the user to split his view as he pleases into multiple subviews. Everything is working perfectly fine with one small exception.
The thing is I'd like to distinguish the subviews into two types: a "normal" subview that is resizing with the container, and a "toolbar" subview, that only resizes when the user drags the splitter. The "toolbar" type should automatically resize with the container only in one direction (depending on it's type: either horizontal or vertical).
No matter if I set the AutoresizingMask of the "toolbar" subview to the desired direction or don't set it at all, the subview always gets it's width/height recalculated while changing the size of the container.
I guess the method responsible for resizing the subviews is
adjustSubviews? If so, then I guess what I'm trying to do is possible to accomplish (as the comment states: "
What we want to do is to preserve non resizable sizes first, and then to preserve the ratio of size to available non fixed space for every other subview") but I'm probably doing something wrong.
Does anyone have any suggestions on what I might be doing wrong or how I could solve this issue any other way?
Sorry in advance if this seems trivial but I've started using Cappuccino just a few hours ago.
Konrad