Dom UI Controls serve to edit DOM elements (DomElement class) in UI forms. They have 2 basic methods: commit() and reset(). The former updates DOM Element to match the input in control, the latter - updates UI to match DOM contents. They're usually called by system on top-level editor pages after such events as focus lost and undo. Dom Controls are usually bound to Swing controls by method bind().

Basic controls are:

  • BooleanControl: bound to JCheckBox, edits GenericDomValue<Boolean>
  • BooleanEnumControl: bound to JCheckBox, edits GenericDomValue<? extends Enum>, where enum has 2 elements
  • ComboControl: bound to JComboBox, edits GenericDomValue<T>, where T may be String, enum or something other Editor-based controls, created via DomUIFactory, are bound to special JPanel inheritors:
  • TextControl: bound to TextPanel, MultiLineTextPanel or BigTextPanel (in this case a browse button appears, that opens a dialog to edit the text in large editor)
  • PsiClassControl: bound to PsiClassPanel
  • PsiTypeControl: bound to PsiTypePanel

    BasicDomElementComponent supports auto-binding Swing controls to auto-created corresponding DOM Controls based on parent DOM Element children and class fields, that makes easy to design DOM UI forms.

    DomCollectionControl is table control for viewing and editing collection elements. One should specify parent DOM element, collection child description and ColumnInfo's. The Control is bound to DomCollectionPanel.