|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object uic.widgets.TwoColorListCellRenderer
CellRenderer for the list Has to different colors for the odd and even rows to improve the look
Constructor Summary | |
TwoColorListCellRenderer()
Default constructor, same as new TwoColorListCellRenderer(null) |
|
TwoColorListCellRenderer(ListCellRenderer renderer)
Constructor based on an exisint cellrenderer |
Method Summary | |
Component |
getListCellRendererComponent(JList list,
Object value,
int index,
boolean isSelected,
boolean cellHasFocus)
Return the tweaked list cell renderer component |
boolean |
isPaintFocus()
|
void |
setEvenRowColor(Color bg2)
Set the even row color |
void |
setOddRowColor(Color bg)
Set the odd row color |
void |
setPaintFocus(boolean paintFocus)
Paint the focus if true |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public TwoColorListCellRenderer()
new TwoColorListCellRenderer(null)
public TwoColorListCellRenderer(ListCellRenderer renderer)
renderer
- a cellrenderer that needs to be used for displaying listentries, or null if DefaultListCellRenderer can be usedMethod Detail |
public Component getListCellRendererComponent(JList list, Object value, int index, boolean isSelected, boolean cellHasFocus)
getListCellRendererComponent
in interface ListCellRenderer
public void setOddRowColor(Color bg)
public void setEvenRowColor(Color bg2)
public void setPaintFocus(boolean paintFocus)
public boolean isPaintFocus()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |