类 DecoratableIcon
- java.lang.Object
-
- org.meteoinfo.laboratory.codecomplete.DecoratableIcon
-
- 所有已实现的接口:
javax.swing.Icon
public class DecoratableIcon extends java.lang.Object implements javax.swing.IconAn icon that can have an optional "decorations" icon beside of it.- 版本:
- 1.0
- 作者:
- Robert Futrell
-
-
构造器概要
构造器 构造器 说明 DecoratableIcon(int width, javax.swing.Icon mainIcon)Constructor.DecoratableIcon(javax.swing.Icon mainIcon)Constructor.
-
方法概要
所有方法 实例方法 具体方法 修饰符和类型 方法 说明 voidaddDecorationIcon(javax.swing.Icon decoration)Adds a decoration icon.intgetIconHeight()intgetIconWidth()voidpaintIcon(java.awt.Component c, java.awt.Graphics g, int x, int y)voidsetDeprecated(boolean deprecated)Sets whether this icon is for a deprecated item.voidsetMainIcon(javax.swing.Icon icon)Sets the main icon.
-
-
-
构造器详细资料
-
DecoratableIcon
public DecoratableIcon(javax.swing.Icon mainIcon)
Constructor.- 参数:
mainIcon- The "main" icon. This cannot benull.
-
DecoratableIcon
public DecoratableIcon(int width, javax.swing.Icon mainIcon)Constructor.- 参数:
width- The width for this icon.mainIcon- The "main" icon. This cannot benull.
-
-
方法详细资料
-
addDecorationIcon
public void addDecorationIcon(javax.swing.Icon decoration)
Adds a decoration icon.- 参数:
decoration- A new decoration icon. This cannot benull.- 另请参阅:
setMainIcon(Icon)
-
getIconHeight
public int getIconHeight()
- 指定者:
getIconHeight在接口中javax.swing.Icon
-
getIconWidth
public int getIconWidth()
- 指定者:
getIconWidth在接口中javax.swing.Icon
-
paintIcon
public void paintIcon(java.awt.Component c, java.awt.Graphics g, int x, int y)- 指定者:
paintIcon在接口中javax.swing.Icon
-
setDeprecated
public void setDeprecated(boolean deprecated)
Sets whether this icon is for a deprecated item.- 参数:
deprecated- Whether this icon is for a deprecated item.
-
setMainIcon
public void setMainIcon(javax.swing.Icon icon)
Sets the main icon.- 参数:
icon- The "main" icon. This cannot benull.- 另请参阅:
addDecorationIcon(Icon)
-
-