4

How can i center the content of JTable Header which has a nimbus look and feel? I tried to use DefaultTableCellHeaderRenderer, but it look like this;

JTable Header with Nimbus Look and Feel

is there any way to make them all look like PARENT_ID column's and centered?

mKorbel
  • 109,525
  • 20
  • 134
  • 319
MOD
  • 1,070
  • 3
  • 19
  • 41

1 Answers1

7

This example shows one approach. By using the table header's DefaultTableCellRenderer, it minimizes the impact on the UI delegate's appearance.

Community
  • 1
  • 1
trashgod
  • 203,806
  • 29
  • 246
  • 1,045