Package snap.viewx
Class FormBuilder
java.lang.Object
snap.props.PropObject
snap.view.ViewOwner
snap.viewx.FormBuilder
- All Implemented Interfaces:
PropChange.DoChange
- Direct Known Subclasses:
DialogBox
A class to build a form.
-
Field Summary
Fields inherited from class snap.view.ViewOwner
Action, DragDrop, DragEnter, DragEvents, DragExit, DragGesture, DragOver, KeyEvents, KeyPress, KeyRelease, KeyType, MouseDrag, MouseEnter, MouseEvents, MouseExit, MouseMove, MousePress, MouseRelease, Showing_Prop, WinClose
Fields inherited from class snap.props.PropObject
_pcs, EMPTY_OBJECT
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionaddButtons
(String[] theTitles) Adds buttons.addButtons
(String[] theNames, String[] theLabels) Adds buttons.addComboBox
(String aTitle, String[] options, String aDefault) Adds an option field.Adds a label.addRadioButton
(String aTitle, String theText, boolean isSelected) Adds a radio button.addRadioButtons
(String aTitle, String[] options, String aDefault) Adds radio buttons.Adds a separator.addTextArea
(String aTitle) Adds a TextArea.addTextField
(String aName, String aDefault) Adds a text field.addTextField
(String aLabel, String aName, String aDefault) Adds a text field.<T extends View>
TaddView
(T aView) Adds a View.protected ColView
Creates the FormView.protected View
createUI()
Creates the UI.getFont()
Returns the font.Returns the padding.double
Returns the spacing between components.getStringValue
(String aKey) Returns the specified value.Returns the specified value.<T extends View>
TremoveView
(T aView) Removes a View.protected void
Responds to UI.void
Sets the font.void
setPadding
(double aTp, double aRt, double aBt, double aLt) Sets the padding.void
setPadding
(Insets theInsets) Sets the padding.void
setSpacing
(double aValue) Sets the spacing between components.void
Sets the specified value.boolean
Show Dialog.Methods inherited from class snap.view.ViewOwner
addKeyActionFilter, addKeyActionHandler, addViewEventHandler, beep, cancelReset, createUIForClass, dispatchEventToOwner, enableEvents, fireActionEventForObject, getEnv, getFirstFocus, getImage, getNative, getToggleGroup, getUI, getUI, getUISource, getView, getView, getViewBoolValue, getViewFloatValue, getViewIntValue, getViewItems, getViewSelIndex, getViewSelItem, getViewStringValue, getViewText, getViewValue, getWindow, initShowing, initUI, initWindow, invokeResetUI, invokeRespondUI, isEventThread, isSendEventDisabled, isShowing, isUISet, isViewDisabled, isViewEnabled, isViewVisible, isWindowSet, isWindowVisible, requestFocus, resetLater, resetUI, runDelayed, runLater, setFirstFocus, setSendEventDisabled, setShowing, setViewDisabled, setViewEnabled, setViewItems, setViewItems, setViewSelIndex, setViewSelItem, setViewText, setViewValue, setViewVisible, setWindowVisible
Methods inherited from class snap.props.PropObject
addDeepChangeListener, addPropChangeListener, addPropChangeListener, clone, firePropChange, firePropChange, firePropChange, getPropDefault, getPropForName, getPropParent, getPropSet, getPropsForArchival, getPropsForArchivalExtra, getPropsString, getPropValue, initProps, isPropDefault, processPropChange, removeDeepChangeListener, removePropChangeListener, removePropChangeListener, setPropsString, setPropValue, setPropValues, toString, toStringProps
-
Field Details
-
_formView
-
-
Constructor Details
-
FormBuilder
public FormBuilder()Constructor.
-
-
Method Details
-
getPadding
Returns the padding. -
setPadding
Sets the padding. -
setPadding
public void setPadding(double aTp, double aRt, double aBt, double aLt) Sets the padding. -
getSpacing
public double getSpacing()Returns the spacing between components. -
setSpacing
public void setSpacing(double aValue) Sets the spacing between components. -
getFont
Returns the font. -
setFont
Sets the font. -
addLabel
Adds a label. -
addTextArea
Adds a TextArea. -
addSeparator
Adds a separator. -
addTextField
Adds a text field. -
addTextField
Adds a text field. -
addComboBox
Adds an option field. -
addButtons
Adds buttons. -
addButtons
Adds buttons. -
addRadioButtons
Adds radio buttons. -
addRadioButton
Adds a radio button. -
addView
Adds a View. -
removeView
Removes a View. -
showPanel
Show Dialog. -
getValue
Returns the specified value. -
setValue
Sets the specified value. -
getStringValue
Returns the specified value. -
createFormView
Creates the FormView. -
createUI
Creates the UI. -
respondUI
Responds to UI.
-