Enter the theater
Stage
The User Interface in JavaFX is understood as a kind of drama or spectacle. Including a stage on which a scene is presented as the play. Parts of the scene are the actors and props.
javafx.scene.Stage
The application “acts” on the stage.
How this stage is presented to the audience depends on where the stage is established. E.g. as part of a WebPage, on the desktop or on a tablet.
Scene
javafx.scene.Scene
The scene is the play.
Node
javafx.scene.Node
Nodes are the actors and props of a scene.
All nodes in JavaFX are derived from the class javafx.scene.Node.
Specifically a node can be:
- the various UI controls
- any form (shape)
- text (which is also a shape)
- images
- media player
- embedded browser
- individual UI controls
A Node can also be a (layout) container for other nodes.
A scene has a “scene graph” that represents all the nodes of the scene grouped under a common direction. Individual properties or entire node groups can be manipulated in various ways, e.g. be moved , scaled or colored.
UIs in JavaFX are totally node-centered.
Leave a Reply