Follow along with the video below to see how to install our site as a web app on your home screen.
Anmerkung: This feature may not be available in some browsers.
// Variante 1
BorderPane {
top: VBox {
HBox {
Label
Label
Label
}
Label
}
center: BorderPane {
left: Group {
Button
}
center: Group {
Button
}
right: Group {
Button
}
}
bottom: Label (wrapText: true) // alternativ: TextFlow { Text, Text, ... } oder FlowPane { Label, Label, ... }
}
// Variante 2
VBox {
HBox {
Label
Label
Label
}
Label
Region (stretch vertically)
Hbox {
Button
Region (stretch horizontally)
Button
Region (stretch horizontally)
Button
}
Region (stretch vertically)
Label (wrapText: true) // alternativ: TextFlow { Text, Text, ... } oder FlowPane { Label, Label, ... }
}
supi, danke sehr.Gibt mehrere Varianten, wie man zum Ziel kommen könnte:
Variante 2 ist sicher etwas einfacher, weil weniger tief verschachtelt. Am Ende aber ist es egal.Code:// Variante 1 BorderPane { top: VBox { HBox { Label Label Label } Label } center: BorderPane { left: Group { Button } center: Group { Button } right: Group { Button } } bottom: Label (wrapText: true) // alternativ: TextFlow { Text, Text, ... } oder FlowPane { Label, Label, ... } } // Variante 2 VBox { HBox { Label Label Label } Label Region (stretch vertically) Hbox { Button Region (stretch horizontally) Button Region (stretch horizontally) Button } Region (stretch vertically) Label (wrapText: true) // alternativ: TextFlow { Text, Text, ... } oder FlowPane { Label, Label, ... } }
(Und es gibt sicher noch weitere Kombinationsmöglichkeiten, wie man hier die JavaFX-Layouts verwenden könnte, um zum Ziel zu kommen!)