Package com.illumon.iris.gui.util
Class MultiIcon
java.lang.Object
com.illumon.iris.gui.util.MultiIcon
- All Implemented Interfaces:
Icon
public class MultiIcon extends Object implements Icon
An implementation of
Icon
that renders each icon side by side. Note that this can not generate events
so calling add(Icon)
, remove(Icon)
, etc. will not automatically update the component that this icon
belongs to.-
Constructor Summary
Constructors Constructor Description MultiIcon()
-
Method Summary
Modifier and Type Method Description void
add(Icon icon)
Add the specified icon to the list of icons.void
add(Icon icon, int index)
Insert the specified icon at the designated index.int
getIconHeight()
int
getIconWidth()
int
indexOf(Icon icon)
Find the index of the specified icon in the collection.void
paintIcon(Component c, Graphics g, int x, int y)
boolean
remove(Icon icon)
Remove the specified icon from this MultiIcon.void
removeAll()
Remove all icons from the list.
-
Constructor Details
-
MultiIcon
public MultiIcon()
-
-
Method Details
-
indexOf
Find the index of the specified icon in the collection.- Parameters:
icon
- The icon to search for.- See Also:
List.indexOf(Object)
-
remove
Remove the specified icon from this MultiIcon. -
add
Add the specified icon to the list of icons. -
add
Insert the specified icon at the designated index.- See Also:
List.add(int, Object)
-
removeAll
public void removeAll()Remove all icons from the list. -
paintIcon
-
getIconWidth
public int getIconWidth()- Specified by:
getIconWidth
in interfaceIcon
-
getIconHeight
public int getIconHeight()- Specified by:
getIconHeight
in interfaceIcon
-