Stylesentities set up (Figure 13.6).
Viewis constructed. You even have the option of specifying it as a
Fragmentinstead through the Type parameter, as well as an FXML via Kind. Finally, you can specify the
Nodetype for the Root, which should default to a
Viewwill generated and added to your project (Figure 13.9).
Viewgenerated with the TornadoFX plugin
Componentinjections quickly with the plugin. For instance, if you right click the class body of the
MainView, you can generate the
MyOtherViewas an injected property (Figure 13.10).
MyOtherViewas the injected property, then click OK (Figure 13.11).
Clientclass should now look like this.
Clientnow uses JavaFX properties instead of plain properties. Notice the primary constructor will pass the intial values to the
property()delegates, but you do not have to provide initial values if they are not desired.
TableView. If you have a
TableView<Person>, you can put the cursor on its declaration, press ALT + ENTER, and get a prompt to generate the columns (Figure 13.13).
Personproperties to generate the columns on (Figure 14.14).
TableView<T>, this feature only works if the properties on
Tfollow the JavaFX convention using the