Java Reference
In-Depth Information
SwingRadioButton
{
text:"Manager"
toggleGroup:
rdoBtns
id:"mngr"}
SwingRadioButton
{
text:"Janitor"
toggleGroup:
rdoBtns
id:"gntr"}
]
}
]
}
var
attndRow
= HBox {spacing:7
nodeVPos:VPos.CENTER
content:[
SwingCheckBox
{id:"isattnd"
text:"Mark as Attendee"}
]
}
var btnRow = HBox {
spacing:7
content:[
SwingButton
{
text:"Submit"
action:function(){
// display data
}
}
SwingButton
{text:"Clear"}
]
}
When the code runs, it will produce the form shown in the next screenshot. Compare this to
the form produced by using JavaFX controls in the recipe
Creating a form with JavaFX controls
.