CHAPTER 6

image

Understanding Nodes

In this chapter, you will learn:

  • What a node is in JavaFX
  • About the Cartesian coordinate system
  • About the bounds and bounding box of nodes
  • How to set the size of a node and how to position a node
  • How to store user data in a node
  • What a managed node is
  • How to transform node’s bounds between coordinate spaces

What Is a Node?

Chapter 5 introduced you to scenes and scene graphs. A scene graph is a tree data structure. Every item in a scene graph is called a node. An instance of the javafx.scene.Node class represents a node in the scene graph. Note that the Node class is an abstract class, and several concrete classes ...

Get Learn JavaFX 8: Building User Experience and Interfaces with Java 8 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.