JavaFx StackPane in SceneBuilder, how to make only front pane visible without setting disabling visibility of others?

前端 未结 2 1662
情话喂你
情话喂你 2021-01-24 11:13

Related question: Nodes - Choose the Layer to appear JavaFX2

I\'m using JavaFx 8 with SceneBuilder 2. I have a number of panes as children of a StackPane and I would lik

相关标签:
2条回答
  • 2021-01-24 12:11

    You could try setting the visibility to false. To do that, call setVisible(false) on the node you'd like to render invisible in the StackPane.

    See Node::setVisible

    0 讨论(0)
  • 2021-01-24 12:15

    The answer is to set the background colour of the panes. Opacity has no effect without first setting a background colour.

    0 讨论(0)
提交回复
热议问题