0

As you can see in this picture all the characters are selected but I want it differently. I want it to act as a radio button, for example when I click one character all other characters should be deselected.

Andrew Thompson
  • 168,117
  • 40
  • 217
  • 433
  • 1
    You might put them in a `JList` with single selection enabled. Getting the horizontal layout is easy, but the exact layout and look might be tricky. – Andrew Thompson Nov 10 '16 at 10:56
  • 1
    Also consider `JToggleButton` with `Icon` in a `ButtonGroup`, for [example](http://stackoverflow.com/a/22643334/230513). – trashgod Nov 10 '16 at 11:07

1 Answers1

0

You can simply use a if statement to Disable or make all rest of the labels invisible as soon as any one of them is selected.