Class HSBChooser

  • All Implemented Interfaces:
    java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, javax.accessibility.Accessible, javax.swing.plaf.UIResource

    public class HSBChooser
    extends SliderBasedChooser<HSBColorSliderModel>
    implements javax.swing.plaf.UIResource
    A ColorChooser with HSB sliders.
    Version:
    1.3 2006-04-23 Retrieve labels from UIManager.
    1.2 2005-11-22 Moved handler for text fields into separate class.
    1.2.1 2005-11-07 Get "Labels" resource bundle from UIManager.
    1.2 2005-09-05 Get font, spacing and icon from UIManager.
    1.1.1 2005-04-23 Localized form.
    1.0 29 March 2005 Created.
    See Also:
    Serialized Form
    • Nested Class Summary

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

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

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

        java.awt.Container.AccessibleAWTContainer
      • Nested classes/interfaces inherited from class java.awt.Component

        java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private javax.swing.JTextField brightnessField  
      private javax.swing.JLabel brightnessFieldLabel  
      private javax.swing.JPanel brightnessFieldPanel  
      private javax.swing.JLabel brightnessLabel  
      private javax.swing.JSlider brightnessSlider  
      private javax.swing.JTextField hueField  
      private javax.swing.JLabel hueFieldLabel  
      private javax.swing.JPanel hueFieldPanel  
      private javax.swing.JLabel hueLabel  
      private javax.swing.JSlider hueSlider  
      private javax.swing.JTextField saturationField  
      private javax.swing.JLabel saturationFieldLabel  
      private javax.swing.JPanel saturationFieldPanel  
      private javax.swing.JLabel saturationLabel  
      private javax.swing.JSlider saturationSlider  
      private javax.swing.JPanel springPanel  
      • Fields inherited from class javax.swing.colorchooser.AbstractColorChooserPanel

        TRANSPARENCY_ENABLED_PROPERTY
      • Fields inherited from class javax.swing.JComponent

        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

        accessibleContext, 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 Description
      HSBChooser()
      Creates new form.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      private void brightnessFieldFocusLost​(java.awt.event.FocusEvent evt)  
      protected void buildChooser()  
      java.lang.String getDisplayName()  
      javax.swing.Icon getLargeDisplayIcon()  
      javax.swing.Icon getSmallDisplayIcon()  
      private void hueFieldFocusLost​(java.awt.event.FocusEvent evt)  
      private void initComponents()
      This method is called from within the constructor to initialize the form.
      private void saturationFieldFocusLost​(java.awt.event.FocusEvent evt)  
      • Methods inherited from class javax.swing.colorchooser.AbstractColorChooserPanel

        getColorFromModel, getColorSelectionModel, getDisplayedMnemonicIndex, getMnemonic, installChooserPanel, isColorTransparencySelectionEnabled, paint, setColorTransparencySelectionEnabled, uninstallChooserPanel
      • Methods inherited from class javax.swing.JPanel

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

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

        add, add, add, add, add, addContainerListener, addImpl, 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, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
      • Methods inherited from class java.awt.Component

        action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, 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, getName, getParent, 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, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • brightnessField

        private javax.swing.JTextField brightnessField
      • brightnessFieldLabel

        private javax.swing.JLabel brightnessFieldLabel
      • brightnessFieldPanel

        private javax.swing.JPanel brightnessFieldPanel
      • brightnessLabel

        private javax.swing.JLabel brightnessLabel
      • brightnessSlider

        private javax.swing.JSlider brightnessSlider
      • hueField

        private javax.swing.JTextField hueField
      • hueFieldLabel

        private javax.swing.JLabel hueFieldLabel
      • hueFieldPanel

        private javax.swing.JPanel hueFieldPanel
      • hueLabel

        private javax.swing.JLabel hueLabel
      • hueSlider

        private javax.swing.JSlider hueSlider
      • saturationField

        private javax.swing.JTextField saturationField
      • saturationFieldLabel

        private javax.swing.JLabel saturationFieldLabel
      • saturationFieldPanel

        private javax.swing.JPanel saturationFieldPanel
      • saturationLabel

        private javax.swing.JLabel saturationLabel
      • saturationSlider

        private javax.swing.JSlider saturationSlider
      • springPanel

        private javax.swing.JPanel springPanel
    • Constructor Detail

      • HSBChooser

        public HSBChooser()
        Creates new form.
    • Method Detail

      • buildChooser

        protected void buildChooser()
        Specified by:
        buildChooser in class javax.swing.colorchooser.AbstractColorChooserPanel
      • getDisplayName

        public java.lang.String getDisplayName()
        Specified by:
        getDisplayName in class javax.swing.colorchooser.AbstractColorChooserPanel
      • getLargeDisplayIcon

        public javax.swing.Icon getLargeDisplayIcon()
        Specified by:
        getLargeDisplayIcon in class javax.swing.colorchooser.AbstractColorChooserPanel
      • getSmallDisplayIcon

        public javax.swing.Icon getSmallDisplayIcon()
        Specified by:
        getSmallDisplayIcon in class javax.swing.colorchooser.AbstractColorChooserPanel
      • initComponents

        private void initComponents()
        This method is called from within the constructor to initialize the form. WARNING: Do NOT modify this code. The content of this method is always regenerated by the Form Editor.
      • brightnessFieldFocusLost

        private void brightnessFieldFocusLost​(java.awt.event.FocusEvent evt)
      • saturationFieldFocusLost

        private void saturationFieldFocusLost​(java.awt.event.FocusEvent evt)
      • hueFieldFocusLost

        private void hueFieldFocusLost​(java.awt.event.FocusEvent evt)