Package com.jidesoft.icons
Class RolloverIcon
java.lang.Object
com.jidesoft.icons.RolloverIcon
- All Implemented Interfaces:
Icon
RolloverIcon provides the expanded and collapsed tree icons that has rollover and fade effect. However
it can be used to implement icon for any other purpose, not just the tree icons.- Since:
- 3.3.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classThe default collapsed tree icon.static classThe default expanded tree icon.static interfaceAn interface that should be implemented on a component if you want to use an icon that supports rollover and fade (fade in or fade out) effect. -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionRolloverIcon(RolloverIcon.IconRolloverSupport rolloverSupport, int iconType) Creates an RolloverIcon.RolloverIcon(RolloverIcon.IconRolloverSupport rolloverSupport, Icon normalIcon) Creates an RolloverIcon.RolloverIcon(RolloverIcon.IconRolloverSupport rolloverSupport, Icon normalIcon, Icon rolloverIcon) Creates an RolloverIcon. -
Method Summary
Modifier and TypeMethodDescriptionintintvoid
-
Field Details
-
COLOR_COLLAPSED_FILL_ROLLOVER
All colors used by the default icons. You can change them to fit your Linvalid input: '&F'. -
COLOR_COLLAPSED_FILL
-
COLOR_COLLAPSED_ROLLOVER
-
COLOR_COLLAPSED
-
COLOR_EXPANDED_FILL_ROLLOVER
-
COLOR_EXPANDED_FILL
-
COLOR_EXPANDED_ROLLOVER
-
COLOR_EXPANDED
-
ICON_EXPANDED
public static final int ICON_EXPANDED- See Also:
-
ICON_COLLAPSED
public static final int ICON_COLLAPSED- See Also:
-
-
Constructor Details
-
RolloverIcon
Creates an RolloverIcon.- Parameters:
rolloverSupport- the IconRolloverSupport interface that should be implemented on a component.iconType- the icon type. It could be eitherICON_EXPANDEDorICON_COLLAPSED.
-
RolloverIcon
Creates an RolloverIcon.- Parameters:
rolloverSupport- the IconRolloverSupport interface that should be implemented on a component.normalIcon- the normal icon
-
RolloverIcon
public RolloverIcon(RolloverIcon.IconRolloverSupport rolloverSupport, Icon normalIcon, Icon rolloverIcon) Creates an RolloverIcon.- Parameters:
rolloverSupport- the IconRolloverSupport interface that should be implemented on a component.normalIcon- the normal icon. This icon will be used to determine the icon size. The size of the rollover icon is ignored so you should make sure the two icons have the same size.rolloverIcon- the rollover icon
-
-
Method Details
-
paintIcon
-
getIconWidth
public int getIconWidth()- Specified by:
getIconWidthin interfaceIcon
-
getIconHeight
public int getIconHeight()- Specified by:
getIconHeightin interfaceIcon
-