Module ij
Package ij.gui

Class ColorChooser

  • All Implemented Interfaces:
    java.awt.event.AdjustmentListener, java.awt.event.TextListener, java.util.EventListener

    public class ColorChooser
    extends java.lang.Object
    implements java.awt.event.TextListener, java.awt.event.AdjustmentListener
    Displays a dialog that allows the user to select a color using three sliders.
    • Constructor Summary

      Constructors 
      Constructor Description
      ColorChooser​(java.lang.String title, java.awt.Color initialColor, boolean useHSB)
      Constructs a ColorChooser using the specified title and initial color.
      ColorChooser​(java.lang.String title, java.awt.Color initialColor, boolean useHSB, java.awt.Frame frame)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void adjustmentValueChanged​(java.awt.event.AdjustmentEvent e)  
      java.awt.Color getColor()
      Displays a color selection dialog and returns the color selected by the user.
      void textValueChanged​(java.awt.event.TextEvent e)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ColorChooser

        public ColorChooser​(java.lang.String title,
                            java.awt.Color initialColor,
                            boolean useHSB)
        Constructs a ColorChooser using the specified title and initial color.
      • ColorChooser

        public ColorChooser​(java.lang.String title,
                            java.awt.Color initialColor,
                            boolean useHSB,
                            java.awt.Frame frame)
    • Method Detail

      • getColor

        public java.awt.Color getColor()
        Displays a color selection dialog and returns the color selected by the user.
      • textValueChanged

        public void textValueChanged​(java.awt.event.TextEvent e)
        Specified by:
        textValueChanged in interface java.awt.event.TextListener
      • adjustmentValueChanged

        public void adjustmentValueChanged​(java.awt.event.AdjustmentEvent e)
        Specified by:
        adjustmentValueChanged in interface java.awt.event.AdjustmentListener