visad.browser
Class ContourWidget
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- java.awt.Panel
-
- visad.browser.Widget
-
- visad.browser.ContourWidget
-
- All Implemented Interfaces:
- java.awt.event.ActionListener, java.awt.event.ItemListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible
public class ContourWidget extends Widget implements java.awt.event.ActionListener, java.awt.event.ItemListener
A widget that allows users to control graphics mode parameters.- See Also:
- Serialized Form
-
-
Field Summary
-
Constructor Summary
Constructors Constructor and Description ContourWidget()Constructs a new ContourWidget.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidactionPerformed(java.awt.event.ActionEvent e)Handles TextField changes.floatgetBase()Gets the value of the base text field.floatgetContourInterval()Gets the value of the interval text field.floatgetHiLimit()Gets the hi value of the contour range slider.booleangetLabels()Gets the value of the labels checkbox.floatgetLowLimit()Gets the low value of the contour range slider.booleangetMainContours()Gets the value of the contours checkbox.doublegetMaxValue()Gets the maximum contouring value.doublegetMinValue()Gets the minimum contouring value.java.lang.StringgetName()Gets the name of the variable.java.lang.StringgetSaveString()Gets a string representing this widget's current state.floatgetSurfaceValue()Gets the value of the surface value slider.voiditemStateChanged(java.awt.event.ItemEvent e)Handles Checkbox changes.static voidmain(java.lang.String[] args)Tests ContourWidget.voidsetBase(float bs)Sets the value of the base text field.voidsetContourInterval(float ci)Sets the value of the interval text field.voidsetLabels(boolean lb)Sets the value of the labels checkbox.voidsetLimits(float lo, float hi)Sets the range of the contour range slider.voidsetMainContours(boolean mc)Sets the value of the contours checkbox.voidsetName(java.lang.String name)Sets the name of the variable.voidsetRange(float min, float max)Sets the minimum and maximum contouring values.voidsetSaveString(java.lang.String save)Reconstructs this widget's state using the specified save string.voidsetSurfaceValue(float sv)Sets the value of the surface value slider.-
Methods inherited from class visad.browser.Widget
addWidgetListener, containedIn, notifyListeners, removeWidgetListener
-
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, isValidateRoot, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, remove, remove, removeAll, removeContainerListener, removeNotify, setComponentZOrder, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, setLayout, transferFocusDownCycle, update, validate
-
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, dispatchEvent, enable, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocusInWindow, reshape, resize, resize, revalidate, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setMinimumSize, setPreferredSize, setSize, setSize, setVisible, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
-
-
-
Method Detail
-
getName
public java.lang.String getName()
Gets the name of the variable.- Overrides:
getNamein classjava.awt.Component
-
setName
public void setName(java.lang.String name)
Sets the name of the variable.- Overrides:
setNamein classjava.awt.Component
-
getMinValue
public double getMinValue()
Gets the minimum contouring value.
-
getMaxValue
public double getMaxValue()
Gets the maximum contouring value.
-
setRange
public void setRange(float min, float max)Sets the minimum and maximum contouring values.
-
getMainContours
public boolean getMainContours()
Gets the value of the contours checkbox.
-
setMainContours
public void setMainContours(boolean mc)
Sets the value of the contours checkbox.
-
getLabels
public boolean getLabels()
Gets the value of the labels checkbox.
-
setLabels
public void setLabels(boolean lb)
Sets the value of the labels checkbox.
-
getSurfaceValue
public float getSurfaceValue()
Gets the value of the surface value slider.
-
setSurfaceValue
public void setSurfaceValue(float sv)
Sets the value of the surface value slider.
-
getContourInterval
public float getContourInterval()
Gets the value of the interval text field.
-
setContourInterval
public void setContourInterval(float ci)
Sets the value of the interval text field.
-
getLowLimit
public float getLowLimit()
Gets the low value of the contour range slider.
-
getHiLimit
public float getHiLimit()
Gets the hi value of the contour range slider.
-
setLimits
public void setLimits(float lo, float hi)Sets the range of the contour range slider.
-
getBase
public float getBase()
Gets the value of the base text field.
-
setBase
public void setBase(float bs)
Sets the value of the base text field.
-
getSaveString
public java.lang.String getSaveString()
Gets a string representing this widget's current state.- Specified by:
getSaveStringin classWidget
-
setSaveString
public void setSaveString(java.lang.String save)
Reconstructs this widget's state using the specified save string.- Specified by:
setSaveStringin classWidget
-
actionPerformed
public void actionPerformed(java.awt.event.ActionEvent e)
Handles TextField changes.- Specified by:
actionPerformedin interfacejava.awt.event.ActionListener
-
itemStateChanged
public void itemStateChanged(java.awt.event.ItemEvent e)
Handles Checkbox changes.- Specified by:
itemStateChangedin interfacejava.awt.event.ItemListener
-
main
public static void main(java.lang.String[] args)
Tests ContourWidget.
-
-
DMelt 3.0 © DataMelt by jWork.ORG