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 voidadd(Icon icon)Add the specified icon to the list of icons.voidadd(Icon icon, int index)Insert the specified icon at the designated index.intgetIconHeight()intgetIconWidth()intindexOf(Icon icon)Find the index of the specified icon in the collection.voidpaintIcon(Component c, Graphics g, int x, int y)booleanremove(Icon icon)Remove the specified icon from this MultiIcon.voidremoveAll()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:
getIconWidthin interfaceIcon
-
getIconHeight
public int getIconHeight()- Specified by:
getIconHeightin interfaceIcon
-