In order to implement multi-line tooltip in a JTable I'm trying to extend the DefaultTableCellRenderer to override createToolTip to use my MultiLineToolTip. When I override createToolTip for a JButton it works fine and I can get a multi-line tooltip. But, when I try to override it in my extended DefaultTableCellRenderer the method never gets called. Any suggestions? Here's my code (there's not much to it):
posted 15 years ago
I'm not sure why but I moved createToolTip to the table instead of the cell renderer and now it works.