I want to know how do I make my internal AnchorPane responsive example: I have a main screen and on this main screen has a configuration button.
When I click this button, it opens another AnchorPane inside the main AnchorPane. The problem is that when the internal AnchorPane is opened, it is not the size of the parent AnchorPane, that is, if I resize the Main AnchorPane, the AnchorPane inside it does not resize it, it stays the default size that is in my SceneBuilder.
How can I make my internal AnchorPane resize along with the main AnchorPane?
This is the button code that adds the internal AnchorPane
@FXML
private AnchorPane adicionarTela;
@FXML
public void abrirTelaConficuracao() throws IOException, Exception {
AnchorPane a = (AnchorPane) FXMLLoader.load(getClass().getResource("TelaConfiguracao.fxml"));
adicionarTela.getChildren().add(a);
}