How to get position(x, y) of lower Node in Borderpane relative to the screen?

Asked

Viewed 45 times

2

I have a Borderpane where you define your bottom value with an Hbox:

borderPane.setBottom(new HBox(children));

I would like to know the position (x,y) mainly the y of Hbox in relation to the screen.

1 answer

2

I found the answer in Stack in English:

Point2D bounds = borderPaneBottom.localToScene(borderPaneBottom.getLayoutBounds().getMinX(), borderPaneBottom.getLayoutBounds().getMinY());
  • Could you include in your reply the link from where you found the answer?

Browser other questions tagged

You are not signed in. Login or sign up in order to post.