1. SplitPane Example
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 | import javafx.geometry.Orientation; import javafx.scene.Node; import javafx.scene.control.SplitPane; public class FxSplitPane implements FxNode { SplitPane pane; public FxSplitPane() { pane = new SplitPane(); pane.setOrientation(Orientation.HORIZONTAL); pane.setDividerPositions(0.5, 0.5); } @Override public SplitPane get() { return pane; } public void setVertical() { pane.setOrientation(Orientation.VERTICAL); } public void add(Node item) { pane.getItems().add(item); } public void add(FxNode item) { pane.getItems().add(item.get()); } } |
댓글 없음:
댓글 쓰기