Class marimba.gui.ValueWidget
All Packages Class Hierarchy This Package Previous Next Index
Class marimba.gui.ValueWidget
java.lang.Object
|
+----marimba.gui.Widget
|
+----marimba.gui.ValueWidget
- public class ValueWidget
- extends Widget
The ValueWidget class, a general class for widgets
that represent a range of values.
- Version:
- 1.12, 11/17/96
- Author:
- Klaas Waslander
-
maxValue
- The highest possible value.
-
minValue
- The lowest possible value.
-
value
- The current value of the valueWidget.
-
ValueWidget()
- Constructor.
-
getIntegerValue()
- Get the integer value of the ValueWidget.
-
getMaxValue()
- Get the maximum value of the ValueWidget.
-
getMinValue()
- Get the minimum value of the ValueWidget.
-
getProperties(PropertyList)
- Get the properties.
-
getRange()
- Get the range of the ValueWidget.
-
getText()
- Return the current value in string representation
as the text of value widgets.
-
getValue()
- Get the value of the ValueWidget.
-
paramString(StringBuffer)
- Debugging.
-
repaint(int, int, int)
- Checks whether the given value and range would require a repaint
when they would become the new value and range.
-
repaintFor(int, int, int)
- Assumes the given values are valid.
-
setMaxValue(int)
- Set the maximum value.
-
setMinValue(int)
- Set the minimum value.
-
setParam(int, int, int)
- Set all parameters of the ValueWidget at once.
-
setProperties(PropertyList)
- Set the properties.
-
setRange(int, int)
- Set the range of the ValueWidget.
-
setValue(int)
- Set the value of the ValueWidget.
-
setValue(Object)
- Set the value of the ValueWidget.
value
public int value
- The current value of the valueWidget.
- See Also:
- getValue, getIntegerValue, setValue, setParam
minValue
public int minValue
- The lowest possible value.
- See Also:
- getMinValue, setMinValue, getRange, setRange, setParam
maxValue
public int maxValue
- The highest possible value.
- See Also:
- getMaxValue, setMaxValue, getRange, setRange, setParam
ValueWidget
public ValueWidget()
- Constructor.
getProperties
public void getProperties(PropertyList list)
- Get the properties.
- Overrides:
- getProperties in class Widget
setProperties
public void setProperties(PropertyList list)
- Set the properties.
- Overrides:
- setProperties in class Widget
getText
public String getText()
- Return the current value in string representation
as the text of value widgets.
- Overrides:
- getText in class Widget
getIntegerValue
public int getIntegerValue()
- Get the integer value of the ValueWidget.
- See Also:
- value
getValue
public Object getValue()
- Get the value of the ValueWidget.
- Overrides:
- getValue in class Widget
- See Also:
- value
getMinValue
public int getMinValue()
- Get the minimum value of the ValueWidget.
- See Also:
- minValue
setMinValue
public void setMinValue(int minValue)
- Set the minimum value.
- See Also:
- minValue
getMaxValue
public int getMaxValue()
- Get the maximum value of the ValueWidget.
- See Also:
- maxValue
setMaxValue
public void setMaxValue(int maxValue)
- Set the maximum value.
- See Also:
- maxValue
setValue
public void setValue(Object value)
- Set the value of the ValueWidget. The value is restricted
by the min and max value.
- Overrides:
- setValue in class Widget
- See Also:
- value
setValue
public synchronized void setValue(int value)
- Set the value of the ValueWidget. The value is restricted
by the min and max value.
- See Also:
- value
getRange
public int getRange()
- Get the range of the ValueWidget.
- See Also:
- minValue, maxValue
setRange
public synchronized void setRange(int minValue,
int maxValue)
- Set the range of the ValueWidget.
The value is adjusted if necessary.
- See Also:
- minValue, maxValue
setParam
public synchronized void setParam(int value,
int minValue,
int maxValue)
- Set all parameters of the ValueWidget at once.
- See Also:
- value, minValue, maxValue
repaint
public boolean repaint(int newValue,
int newMin,
int newMax)
- Checks whether the given value and range would require a repaint
when they would become the new value and range.
This method adjusts the given values to make sure they are valid.
It does not assume the given values are valid.
repaintFor
protected boolean repaintFor(int newValue,
int newMin,
int newMax)
- Assumes the given values are valid. Checks whether these values
would result in a new look that requires a repaint.
The number of repaints can easily be optimized in sub classes
by overriding this method.
paramString
public void paramString(StringBuffer buf)
- Debugging.
- Overrides:
- paramString in class Widget
All Packages Class Hierarchy This Package Previous Next Index