|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel visad.util.StepWidget
public class StepWidget
StepWidget is a slider GUI component with directional step arrows at either end.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected JButton |
back
|
protected int |
cur
|
protected static boolean |
DEBUG
|
protected JButton |
forward
|
protected int |
max
|
protected int |
min
|
protected JSlider |
step
|
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
StepWidget(boolean horizontal)
Constructs a StepWidget. |
Method Summary | |
---|---|
void |
actionPerformed(ActionEvent e)
ActionListener method used with JButtons. |
void |
addChangeListener(ChangeListener l)
Adds a ChangeListener to the widget. |
int |
getMaximum()
Gets the maximum value of the widget. |
Dimension |
getMaximumSize()
Returns the maximum size of the widget. |
int |
getMinimum()
Gets the minimum value of the widget. |
Dimension |
getMinimumSize()
Returns the minimum size of the widget. |
int |
getValue()
Gets the current value of the widget. |
void |
removeChangeListener(ChangeListener l)
Removes a ChangeListener from the widget. |
void |
setBounds(int min,
int max,
int cur)
Sets the minimum, maximum and current values of the slider. |
void |
setEnabled(boolean enabled)
Enables or disables the widget. |
void |
setValue(int cur)
Sets the current value of the widget. |
void |
stateChanged(ChangeEvent e)
ChangeListener method used with JSlider. |
protected void |
updateStep()
Takes action when the slider's current value changes. |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected static final boolean DEBUG
protected JSlider step
protected JButton forward
protected JButton back
protected int min
protected int max
protected int cur
Constructor Detail |
---|
public StepWidget(boolean horizontal)
Method Detail |
---|
public Dimension getMinimumSize()
getMinimumSize
in class JComponent
public Dimension getMaximumSize()
getMaximumSize
in class JComponent
public int getValue()
public int getMinimum()
public int getMaximum()
public void setValue(int cur)
public void setEnabled(boolean enabled)
setEnabled
in class JComponent
public void setBounds(int min, int max, int cur)
public void addChangeListener(ChangeListener l)
public void removeChangeListener(ChangeListener l)
public void actionPerformed(ActionEvent e)
actionPerformed
in interface ActionListener
public void stateChanged(ChangeEvent e)
stateChanged
in interface ChangeListener
protected void updateStep()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |