Extending Builders: Layout Builders (original) (raw)
Tom Eugelink tbee at tbee.org
Thu Nov 22 10:51:33 PST 2012
- Previous message: Extending Builders: Layout Builders
- Next message: Extending Builders: Layout Builders
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Not sure I understand what you are trying to say here. Each layout has different and much deviating constraints, so they cannot be unified into one model.
I think I summarized it well in my blogpost: "All information about the layout of a single node should be stored in one place." This means absolute layout can suffice with the X,Y,W,H information available in the nodes (and thus allow binding), but all more advanced layouts require a separate constraint class.
Tom
On 2012-11-21 22:42, Tom Schindl wrote:
the nice thing about the current expression with static calls is that the semantics for adding children are always the same whether your target is a Layout-Container or e.g. a Group.
You always call add on the target your specified. Your way of layout containers expects two different things to happen: * for layout container you want to call add on the owner because you want to pass the constraint object * you can add on the list itself for stuff like Group but also Tables Not to forget how would you like set the constraint when you not add to a list e.g. when using a borderpane? Tom Am 21.11.12 19:02, schrieb Tom Eugelink: I suspect the constraints were already "out" before FXML, but this would be a fairly acceptable notation:
| <Label fx:id="arrow" alignment="center" text=""_ _maxWidth="Infinity"> | || <HBox.Cvgrow="ALWAYS" hgrow="ALWAYS"|/> |
Or: | <Label fx:id="arrow" alignment="center" text=""_ _maxWidth="Infinity"|||HBox.C.vgrow="ALWAYS" HBox.C.hgrow="ALWAYS"|/> |
On 2012-11-21 17:46, Tom Schindl wrote: Am 21.11.12 09:46, schrieb Richard Bair: I wanted constraint classes from the start. There was a problem there, which I don't accurately remember now, but I do want to see some discussion around deprecating (or at least no longer depending on) the static methods and having some constraint classes again. They've probably been harder to implement in FXML? Tom
- Previous message: Extending Builders: Layout Builders
- Next message: Extending Builders: Layout Builders
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]