jeroen.ui
Class ProcentIcon
java.lang.Object
|
+--jeroen.ui.ProcentIcon
- All Implemented Interfaces:
- Icon
- public class ProcentIcon
- extends Object
- implements Icon
Een Icon die een procent weergeeft.
Zowel als tekst als
met een kleurtje. Rood voor 0%, Groen voor 100%,
en alles ertussenin.
|
Constructor Summary |
ProcentIcon(float waarde)
Nieuwe icon. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ProcentIcon
public ProcentIcon(float waarde)
- Nieuwe icon.
- Parameters:
waarde - getal tussen 0.0 en 1.0 die
aangeeft hoeveel procent het moet zijn.
getIconHeight
public int getIconHeight()
- Specified by:
getIconHeight in interface Icon
getIconWidth
public int getIconWidth()
- Specified by:
getIconWidth in interface Icon
paintIcon
public void paintIcon(Component c,
Graphics g,
int x,
int y)
- Specified by:
paintIcon in interface Icon