Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

TableCellRenderer  RSS feed

 
Alex Kravets
Ranch Hand
Posts: 476
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I have a JTable in which I have cells overloaded to be JCheckBoxes. What I wanted to do was to display cells that are checked in white and those that are not in red. It worked fine (CellRenderer below). However, before the change I had every other row painted in different color. Now that I've added functionality for changing cell's color based on it's value the logic for painting every other row is no longer there. Is there a way I can keep both logics working together?

thanks,
Alex K.
[ July 29, 2003: Message edited by: Alex Kravets ]
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!