org.jhotdraw.draw.action
Class EditorColorIcon
- java.lang.Object
-
- javax.swing.ImageIcon
-
- org.jhotdraw.draw.action.EditorColorIcon
-
- All Implemented Interfaces:
- java.io.Serializable, javax.accessibility.Accessible, javax.swing.Icon
public class EditorColorIcon extends javax.swing.ImageIconEditorColorIcon draws a shape with the color of the specified default attribute of the DrawingEditor onto the icon.The behavior for choosing the drawn color matches with
EditorColorChooserAction.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor and Description EditorColorIcon(DrawingEditor editor, AttributeKey<java.awt.Color> key, java.awt.Image image, java.awt.Shape colorShape)EditorColorIcon(DrawingEditor editor, AttributeKey<java.awt.Color> key, java.net.URL imageLocation, java.awt.Shape colorShape)Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description voidpaintIcon(java.awt.Component c, java.awt.Graphics gr, int x, int y)
-
-
-
Constructor Detail
-
EditorColorIcon
public EditorColorIcon(DrawingEditor editor, AttributeKey<java.awt.Color> key, java.net.URL imageLocation, java.awt.Shape colorShape)
Creates a new instance.- Parameters:
editor- The drawing editor.key- The key of the default attributeimageLocation- the icon imagecolorShape- The shape to be drawn with the color of the default attribute.
-
EditorColorIcon
public EditorColorIcon(DrawingEditor editor, AttributeKey<java.awt.Color> key, java.awt.Image image, java.awt.Shape colorShape)
-
-
DataMelt 3.0 © DataMelt by jWork.ORG