title: JTree with checkboxes
body: <p>I need to add checkboxes to a JTree. A custom TreeCellRenderer/TreeCellEditor seems like the right approach. So far I used <a href="http://www.java2s.com/Code/Java/Swing-JFC/CheckBoxNodeTreeSample.htm" rel="noreferrer">the CheckBoxNodeRenderer approach in this webpage</a>. It works OK except for two things:</p>
  
  <ol>
  <li>there's additional whitespace above + below the checkbox; I'd like to keep it the same as a regular JTree.</li>
  <li>I would like to distinguish between clicking on the checkbox itself (which should attempt to toggle the checkbox) and clicking on the text associated with the checkbox (which should allow an event listener to interpret this as clicking on the corresponding tree node and take whatever action is appropriate)</li>
  </ol>
  
  <p>is there a way to do these things? I looked around for JTrees with checkboxes, can't find much. JIDE looks good but I need to use free open-source software (GPL is not ok, LGPL is ok) in this case. (or create my own checkbox tree)</p>