|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectucar.unidata.idv.ui.ValueSliderComponent
public class ValueSliderComponent
A class for holding a text field and a slider for setting the some integer value
| Field Summary | |
|---|---|
protected Object |
callingObject
readout for value |
| Constructor Summary | |
|---|---|
ValueSliderComponent(Object co,
int min,
int max,
String property,
String label)
Create a ValueSliderComponent |
|
ValueSliderComponent(Object co,
int min,
int max,
String property,
String label,
float scale,
boolean andSet)
Create a ValueSliderComponent |
|
ValueSliderComponent(Object co,
int min,
int max,
String property,
String label,
float scale,
boolean andSet,
String tip)
Create a ValueSliderComponent |
|
| Method Summary | |
|---|---|
void |
doRemove()
Remove the reference to the displayControl |
JComponent |
getContents(boolean withLabel)
Get the GUI contents |
boolean |
getObjectHasInitialized()
Has the calling object been initialized? Subclasses should override if necessary. |
float |
getValue()
Get the value of the widget |
void |
logException(String msg,
Exception exc)
Shortcut to logging facility for subclasses to use |
void |
setEnabled(boolean enable)
Enable or disable the widget. |
void |
setPaintLabels(boolean value)
Set the property on the slider |
void |
setPaintTicks(boolean value)
Set the property on the slider |
void |
setSnapToTicks(boolean value)
Set the property on the slider |
void |
setValue(float value)
Set the value on the widget. |
void |
setValue(int value)
Set the value on the widget. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected Object callingObject
| Constructor Detail |
|---|
public ValueSliderComponent(Object co,
int min,
int max,
String property,
String label)
co - calling objectmin - minimum slider valuemax - maximum slider valueproperty - Object's property to setlabel - label for the widget
public ValueSliderComponent(Object co,
int min,
int max,
String property,
String label,
float scale,
boolean andSet)
co - calling objectmin - minimum slider valuemax - maximum slider valueproperty - Object's property to setlabel - label for the widgetscale - scale factor for the valuesandSet - set the property on the calling object if true
public ValueSliderComponent(Object co,
int min,
int max,
String property,
String label,
float scale,
boolean andSet,
String tip)
co - calling objectmin - minimum slider valuemax - maximum slider valueproperty - calling object property to setlabel - label for the widgetscale - scale factor for the valuesandSet - set the property on the calling object if truetip - tool tip text for the widget| Method Detail |
|---|
public JComponent getContents(boolean withLabel)
withLabel - true if the component should include the label
public void setValue(int value)
value - new valuepublic void setValue(float value)
value - new valuepublic float getValue()
public void setEnabled(boolean enable)
enable - true to enablepublic void setSnapToTicks(boolean value)
value - true to snap slider to tickspublic void setPaintTicks(boolean value)
value - true to paint slider tickspublic void setPaintLabels(boolean value)
value - true to paint slider labelspublic boolean getObjectHasInitialized()
public void logException(String msg,
Exception exc)
msg - error messageexc - error Exceptionpublic void doRemove()
doRemove in interface Removable
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||