(note insure JavaFX 2 plugin is active otherwise JavaFX>EmptyFXML is not available)
- File >New Project >Java with Maven >FXML JavaFx Maven Archetype (Gluon) >....
- File >New File > other > JavaFX > Empty FXML
- Checkbox Use Java Controllers
- Put the controller in package "newpackage"
Notice that the file FXML.java in the editor shows an error
Things compile but if you try to use the new controller/fxml there is a runtime error.
The problem is fixed by adding these lines to moduleinfo
This should be done automatically by the wizard.
Notice that after adding these lines, the editor error indication in the fxml file goes away.