|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.neatech.climbplan.userinterface.components.CloseableTabbedPane.CloseTabIcon
class CloseableTabbedPane.CloseTabIcon
The class which generates the 'X' icon for the tabs. The constructor accepts an icon which is extra to the 'X' icon, so you can have tabs like in JBuilder. This value is null if no extra icon is required.
Field Summary | |
---|---|
private Icon |
fileIcon
the additional fileicon |
private int |
height
the height the icon |
private boolean |
mouseover
true whether the mouse is over this icon, false otherwise |
private boolean |
mousepressed
true whether the mouse is pressed on this icon, false otherwise |
private int |
width
the width the icon |
private int |
x_pos
the x position of the icon |
private int |
y_pos
the y position of the icon |
Constructor Summary | |
---|---|
CloseableTabbedPane.CloseTabIcon(Icon fileIcon)
Creates a new instance of CloseTabIcon |
Method Summary | |
---|---|
Rectangle |
getBounds()
Gets the bounds of this icon in the form of a Rectangle |
int |
getIconHeight()
Returns the icon's height. |
int |
getIconWidth()
Returns the icon's width. |
void |
paintIcon(Component c,
Graphics g,
int x,
int y)
Draw the icon at the specified location. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private int x_pos
private int y_pos
private int width
private int height
private Icon fileIcon
private boolean mouseover
private boolean mousepressed
Constructor Detail |
---|
public CloseableTabbedPane.CloseTabIcon(Icon fileIcon)
CloseTabIcon
fileIcon
- the additional fileicon, if there is one setMethod Detail |
---|
public void paintIcon(Component c, Graphics g, int x, int y)
paintIcon
in interface Icon
c
- the component which the icon belongs tog
- the graphic object to draw onx
- the upper left point of the icon in the x directiony
- the upper left point of the icon in the y directionpublic int getIconWidth()
getIconWidth
in interface Icon
public int getIconHeight()
getIconHeight
in interface Icon
public Rectangle getBounds()
Rectangle
object. The bounds specify this icon's width, height, and location
relative to its parent.
- Returns:
- a rectangle indicating this icon's bounds
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |