Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Why can't I set AnchorPane's resizable attribute?

Tags:

javafx

I created a FXML file using JavaFX Scene Builder 1.1. An AnchorPane is created by default. Why can't I modify the resizable attribute?

enter image description here

like image 607
Ciel Avatar asked Feb 21 '14 12:02

Ciel


People also ask

How do you make AnchorPane resizable?

You can indirectly effect the bounds properties and directly set the resizable properties of the node by altering the min, pref and max height and width. You can also set the pref size by selecting the pane to be resized and dragging the resizing anchors the surround the selected pane.

What is An AnchorPane?

AnchorPane allows the edges of child nodes to be anchored to an offset from the anchor pane's edges. If the anchor pane has a border and/or padding set, the offsets will be measured from the inside edge of those insets.


1 Answers

Do you want to disable window resizing? If so, you can do that in your application program:

stage.setResizable(false);
like image 98
Ginchen Avatar answered Sep 28 '22 11:09

Ginchen