Size of a BorderPane left side
Richard Bair
richard.bair at oracle.com
Mon Aug 26 12:31:08 PDT 2013
The right place for these questions is on the OTN forums. This list is for development of the platform itself:
https://forums.oracle.com/community/developer/english/java/javafx/javafx_2.0_and_later
Thanks
Richard
On Aug 26, 2013, at 11:02 AM, Peter Penzov <peter.penzov at gmail.com> wrote:
> I wan to get the size of the left side of a BorderPane In JavaFX 8. I
> tested this:
>
>
> mainPanel.getRight().getBoundsInLocal().getWidth();
>
>
>
> I think that this is not the correct way. Can you show me how I can do this
> if it's possible?
>
>
>
> I tested this code:
>
>
>
> I get the width of the Left side of a BorderPane, then I set the width of a
> TabPane:
>
>
>
> BorderPane mainPanel new BorderPane();
> tabPane.setPrefWidth(mainPanel.getRight().getBoundsInLocal().getWidth());
>
>
>
>
> I get NPE. Can you help me to correct my mistake? I want when I resize the
> Center of the BorderPane to update the size of the TabPane(shrink it or
> expand it dynamically).
More information about the openjfx-dev
mailing list