• Post Reply Bookmark Topic Watch Topic
  • New Topic

BoxLayout alignment

 
Liz Hundy
Greenhorn
Posts: 11
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have a JPanel with vertical BoxLayout.
I have added 3 JRadioButtons

When I setAlignmentX(Component.LEFT_ALIGNMENT) their left sides are lined up, but they go to the right of the panel.
When I setAlignmentX(Component.RIGHT_ALIGNMENT) their right sides are in line, but they are on the left of the panel.

How can I get them on the left of the panel, with their left sides in line?

By the way there are lots of other things in the panel as well, comboboxes and other panels (spread to fill), lists (centered) ...

---Liz
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!