API addition to SplitPane
richard.bair at oracle.com
Fri Jan 13 10:32:50 PST 2012
On Jan 12, 2012, at 12:22 PM, Daniel Zwolenski wrote:
> Just wondering if there's a case for making it a weighting system (not sure
> how useful this would be, but worth a quick thought):
> resizeWeight(Node node, float weight)
> Where the weight determines what percentage of the 'new' space the node
> gets (and how much it loses when shrinking) and a weight of zero is
> equivalent to your 'false'.
My initial reaction was the same, although I would have used the "ALWAYS", "SOMETIMES", "NEVER" system used by GridPane.
Jasper, can you articulate why you think the boolean is preferable?
> Also, need to handle the case when the parent gets so small that all the
> 'resizable' nodes are already at zero. I assume in this case the nodes with
> resizable=false will actually start to shrink (alternatively the parent
> pane should not be allowed to go any smaller).
Ya, basically this is a system of layout requests "Please, I'd prefer not to be resized" but if it has to, it will. Note that a setMinWidth etc is going onto Stage in a few days here, so at least you will be able to create a window where the user cannot shrink it past a certain point.
More information about the openjfx-dev