A JavaFx version of the Lemur PropertyPanel.
Originally written for the Lemur GUI framework by @pspeed - this is a straight rip to work for the JavaFx framework.
The propertyPanel is a JavaFx GridPane that automatically adds properties or fields from a class and binds them to a control. Changes made to the controls are set on the fields automatically.
So if you bind a float you get a slider. If you change the slider the float will also be changed.
JavaFxPropertyPanel propertyPanel = new JavaFxPropertyPanel(); propertyPanel.addBooleanProperty("Boolean", this, "testBool"); propertyPanel.addFloatProperty("Float", this, "testFloat", 0, 10, 0.1f); propertyPanel.addDoubleProperty("Double", this, "testDouble", 0, 20, 0.1d); propertyPanel.addIntProperty("Int", this, "testInt", 0, 30, 1); propertyPanel.addEnumProperty("Enum", this, "testEnum");
The image below shows me binding property panels to two terrain noise filters so I can adjust the settings to get the terrain how I want it.