Class ColouredSquareMenuItem

All Implemented Interfaces:
ImageObserver, ItemSelectable, MenuContainer, Serializable, Accessible, MenuElement, SwingConstants

public class ColouredSquareMenuItem extends JMenuItem
See Also:
  • Constructor Details

    • ColouredSquareMenuItem

      public ColouredSquareMenuItem(String displayText, byte state)
  • Method Details

    • setSquareColor

      public void setSquareColor(Color c)
      Sets the color of the square.
    • paintComponent

      public void paintComponent(Graphics g)
      Draw a coloured square at the end of the display.
      Overrides:
      paintComponent in class JComponent
    • getVisibleIndicator

      public VisibleIndicator getVisibleIndicator()