public interface ISpinner<T extends java.lang.Number>
Wrapper interface for a spinner-like SWT widget which supports numnbers and helpful key commands for value manipulation
Modifier and Type | Method and Description |
---|---|
org.eclipse.swt.widgets.Control |
getControl()
Returns the Text control widget wrapped in this RealSpinner instance
|
java.lang.String |
getName()
Getter method for the name.
|
T |
getValue()
Returns the real input value
|
void |
listen(ISpinnerListener listener)
Adds a RealSpinnerListener to its listeners list to be notified of
changes to the value
|
void |
setBounds(T minimum,
T maximum)
Sets the minimum and maximum bounds (inclusive)
|
void |
setName(java.lang.String name)
Setter method for the name.
|
void |
setValue(T value)
Replaces the value with the given number
|
void |
setVisible(boolean visible)
Sets the spinner's visibility.
|
T getValue()
Returns the real input value
The value
void setBounds(T minimum, T maximum)
Sets the minimum and maximum bounds (inclusive)
minimum
- The minimum value to enforce
maximum
- The maximum value to enforce
void listen(ISpinnerListener listener)
listener
- The listener to notified of changes to the valueorg.eclipse.swt.widgets.Control getControl()
java.lang.String getName()
void setName(java.lang.String name)
name
- The name for the property controlled by this spinner.void setValue(T value)
Replaces the value with the given number
value
- The new value
void setVisible(boolean visible)
visible
- If false, the spinner's text widget will not be drawn.
Otherwise, the text box will be made visible.