I have a cell in a JTable that in some situations has an icon to the left of it in the same cell. I would like the text to be aligned on the right and the icons on the left. How do I do that?
posted 9 years ago
The default render is a subclass of JLabel, so you can use JLabel methods to alter its look, like it's alignment properties. One thing I've found handy for aligning is to use an empty icon to preserve alignments: