-
Notifications
You must be signed in to change notification settings - Fork 0
Home
Dim edited this page Apr 15, 2019
·
6 revisions
Welcome to the de.dc.emf.javafx.xtext.lang wiki!
This section will describe how to define the controls in javafxlang. You can find all the examples in the project de.dc.javafx.xcore.example
- First you have to create a file with the extension *.javafxlang
- Each dsl file need the packagePath, this is required for the infer path
- All the controls get get into the controls{...} section. This can has more than one control, e.g. TableViewFX
- The TableViewFX should has an unique name and a referencing usedModel, so you have to create a pojo usedMode, here: Contact
- The minimalistic column definition is column(name), this will generate a column with the default width 200.0 and it will not used for filtering. To deactivate filtering use the syntax useFilter. The column will show the value of the property name, which is set on name. If another value should be shown on this side, a custom CellValueFactory can set. The custom CellValueFactory should enhanced by the super class de.dc.javafx.xcore.lang.lib.feature.CellValueFactory.
- The TableViewFX as optionally a propertyview and toolbar for searching
- To generate a TableViewFX application the generateDemo should be activate.
packagePath "de.dc.javafx.xcore.example"
controls{
TableViewFX{
name: ContactTable
usedModel: de.dc.javafx.xcore.example.model.Contact
column(name:Name)
column(name:Age cellValueFactory: AgeTreeCellFeature useFilter)
column(name:Gender cellValueFactory: GenderTreeCellFeature)
column(name:Address)
showPropertyView: false
showToolbar: true
generateDemo: true
}
}