Articles

TiwulFX 2.0 Beta for Java8

TiwulFX 2.0 works with Java8. Please go to Download page to get this release. If you are using java 1.7 you can use version 1.3.

Here are the new features:

  1. Validation of a cell in TableControl is executed on commitEdit event. The validation popup also has better appearance.
  2. Load, save and delete in TableControl are executed in background tasks. A progress indicator is displayed if the task is running. At this time, TableControl buttons are disabled.
  3. TextColumn has 2 handy properties: maxLength and capitalize. The first one is to restrict how many characters TextColumn can accept. The second is to make its characters capitalized.
  4. DetachableTabPane can have custom SceneFactory.
  5. TypeAheadField/Control/Column will make you forget ComboBox. It has filter-as-user-type capability. Also typeAheadField.addItem(String Label,Object object) is a handy method to add an item along with its label without having to create custom StringConverter.
  6. DateControl & DateColumn now use JavaFX’s DatePicker. There are also LocalDateControl and LocalDateColumn components.
  7. Save column position is a new feature to keep user’s preference of column order. Just set tableControl.setConfigurationID(String uniqueId) to activate this feature. You can set this property in FXML file as well. To reset the column position, take a look at gear button at the bottom right of TableControl. You’ll find something there.
  8. Able to define columns in FXML file.
  9. JavaFX TableView notorious of its lack of refresh method. TiwulFX TableControl provide not only one, but two. First, tableContro.refresh() to refresh the whole rows. The second, tableControl.refresh(R record) to refresh particular row that hold specified record. Take a look at TiwulFX Demo – Synchronized Columns.
  10. Get the list of changes from TableControl. Useful if we want to log all changes in a separate table.
  11. And the most important thing for developer, customizing or extending TiwulFX is easier now. Columns and their cells are in separates classes. For example, to add a custom behavior to textField in TextColumn, just extends TextTableCell, and override getEditor() method. You’ll get reference to the editor component (textfield in this case) so you can add listener, or custom behavior to it. And finally set the column’s cellFactory with yours.

 

Lastly, please give us feedback. If you have feature request, or find a bug, let us know in our issue tracker.