Documentation of 'visad.util.BarSlider' Java class
BarSlider
visad.util

Class BarSlider

  • All Implemented Interfaces:
    java.awt.event.MouseListener, java.awt.event.MouseMotionListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible


    public class BarSlider
    extends Slider
    implements java.awt.event.MouseListener, java.awt.event.MouseMotionListener
    The visad utillity sliding bar
    Since:
    Visad Utility Library v0.7.1
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from class javax.swing.JComponent

        javax.swing.JComponent.AccessibleJComponent
      • Nested classes/interfaces inherited from class java.awt.Component

        java.awt.Component.BaselineResizeBehavior
    • Field Summary

      • Fields inherited from class javax.swing.JComponent

        TOOL_TIP_TEXT_KEY, 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

      Constructors 
      Constructor and Description
      BarSlider()
      Construct a new bar slider with the default values
      BarSlider(float lower, float upper, float initial)
      Construct a new bar slider with the givden lower, upper and initial values
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method and Description
      float getMaximum()
      Return the maximum value of this slider
      java.awt.Dimension getMaximumSize()
      Return the maximum size of the bar slider
      float getMinimum()
      Return the minimum value of this slider
      java.awt.Dimension getMinimumSize()
      Return the minimum size of the bar slider
      java.awt.Dimension getPreferredSize()
      Return the preferred sise of the bar slider
      float getValue()
      Returns the current value of the slider
      static void main(java.lang.String[] argv)
      For testing puropses
      void mouseClicked(java.awt.event.MouseEvent e)
      Present to implement MouseListener, currently ignored
      void mouseDragged(java.awt.event.MouseEvent e)
      Updates the slider position
      void mouseEntered(java.awt.event.MouseEvent e)
      Present to implement MouseListener, currently ignored
      void mouseExited(java.awt.event.MouseEvent e)
      Present to implement MouseListener, currently ignored
      void mouseMoved(java.awt.event.MouseEvent e)
      Present to implement MouseMovementListener, currently ignored
      void mousePressed(java.awt.event.MouseEvent e)
      Moves the slider to the clicked position
      void mouseReleased(java.awt.event.MouseEvent e)
      Present to implement MouseListener, currently ignored
      void paint(java.awt.Graphics g)
      Redraw the slider
      void setMaximum(float value)
      Sets the maximum value of this scrolbar
      void setMaximumSize(java.awt.Dimension dim)
      Set the preferred size of the bar slider
      void setMinimum(float value)
      Sets the minimum value for this slider
      void setMinimumSize(java.awt.Dimension dim)
      Set the preferred size of the bar slider
      void setPreferredSize(java.awt.Dimension dim)
      Set the preferred size of the bar slider
      void setValue(float value)
      Sets the current value of the slider
      void update(java.awt.Graphics g)
      update the slider
      • Methods inherited from class javax.swing.JPanel

        getAccessibleContext, getUI, getUIClassID, setUI, updateUI
      • Methods inherited from class javax.swing.JComponent

        addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paintImmediately, paintImmediately, print, printAll, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setNextFocusableComponent, setOpaque, setRequestFocusEnabled, setToolTipText, setTransferHandler, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction
      • Methods inherited from class java.awt.Container

        add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate
      • Methods inherited from class java.awt.Component

        action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, contains, createImage, createImage, createVolatileImage, createVolatileImage, dispatchEvent, enable, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • BarSlider

        public BarSlider()
        Construct a new bar slider with the default values
      • BarSlider

        public BarSlider(float lower,
                         float upper,
                         float initial)
        Construct a new bar slider with the givden lower, upper and initial values
        Throws:
        IllegalArgumenentException - if lower is not less than initial or initial is not less than upper
    • Method Detail

      • main

        public static void main(java.lang.String[] argv)
        For testing puropses
      • getMinimum

        public float getMinimum()
        Return the minimum value of this slider
        Specified by:
        getMinimum in class Slider
      • setMinimum

        public void setMinimum(float value)
        Sets the minimum value for this slider
        Specified by:
        setMinimum in class Slider
      • getMaximum

        public float getMaximum()
        Return the maximum value of this slider
        Specified by:
        getMaximum in class Slider
      • setMaximum

        public void setMaximum(float value)
        Sets the maximum value of this scrolbar
        Specified by:
        setMaximum in class Slider
      • getValue

        public float getValue()
        Returns the current value of the slider
        Specified by:
        getValue in class Slider
      • setValue

        public void setValue(float value)
        Sets the current value of the slider
        Specified by:
        setValue in class Slider
        Throws:
        java.lang.IllegalArgumentException - if the new value is out of bounds for the slider
      • getPreferredSize

        public java.awt.Dimension getPreferredSize()
        Return the preferred sise of the bar slider
        Overrides:
        getPreferredSize in class javax.swing.JComponent
      • setPreferredSize

        public void setPreferredSize(java.awt.Dimension dim)
        Set the preferred size of the bar slider
        Overrides:
        setPreferredSize in class javax.swing.JComponent
      • getMaximumSize

        public java.awt.Dimension getMaximumSize()
        Return the maximum size of the bar slider
        Overrides:
        getMaximumSize in class javax.swing.JComponent
      • setMaximumSize

        public void setMaximumSize(java.awt.Dimension dim)
        Set the preferred size of the bar slider
        Overrides:
        setMaximumSize in class javax.swing.JComponent
      • getMinimumSize

        public java.awt.Dimension getMinimumSize()
        Return the minimum size of the bar slider
        Overrides:
        getMinimumSize in class javax.swing.JComponent
      • setMinimumSize

        public void setMinimumSize(java.awt.Dimension dim)
        Set the preferred size of the bar slider
        Overrides:
        setMinimumSize in class javax.swing.JComponent
      • mouseClicked

        public void mouseClicked(java.awt.event.MouseEvent e)
        Present to implement MouseListener, currently ignored
        Specified by:
        mouseClicked in interface java.awt.event.MouseListener
      • mouseEntered

        public void mouseEntered(java.awt.event.MouseEvent e)
        Present to implement MouseListener, currently ignored
        Specified by:
        mouseEntered in interface java.awt.event.MouseListener
      • mouseExited

        public void mouseExited(java.awt.event.MouseEvent e)
        Present to implement MouseListener, currently ignored
        Specified by:
        mouseExited in interface java.awt.event.MouseListener
      • mousePressed

        public void mousePressed(java.awt.event.MouseEvent e)
        Moves the slider to the clicked position
        Specified by:
        mousePressed in interface java.awt.event.MouseListener
      • mouseReleased

        public void mouseReleased(java.awt.event.MouseEvent e)
        Present to implement MouseListener, currently ignored
        Specified by:
        mouseReleased in interface java.awt.event.MouseListener
      • mouseDragged

        public void mouseDragged(java.awt.event.MouseEvent e)
        Updates the slider position
        Specified by:
        mouseDragged in interface java.awt.event.MouseMotionListener
      • mouseMoved

        public void mouseMoved(java.awt.event.MouseEvent e)
        Present to implement MouseMovementListener, currently ignored
        Specified by:
        mouseMoved in interface java.awt.event.MouseMotionListener
      • update

        public void update(java.awt.Graphics g)
        update the slider
        Overrides:
        update in class javax.swing.JComponent
      • paint

        public void paint(java.awt.Graphics g)
        Redraw the slider
        Overrides:
        paint in class javax.swing.JComponent

DMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.