Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

layout problem  RSS feed

 
Anonymous
Ranch Hand
Posts: 18944
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

hi all,
i want to display ten radio buttons on a single panel in the center
of the screen.they are coming on left even if i give BorderLayout.NORTH
they go towards left.pl. guide
regards
srijan
 
Jim Yingst
Wanderer
Sheriff
Posts: 18671
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It sounds like the panel currently has a FlowLayout as its LaoutManager - which is not surprising, since that's the default for a Panel. You must use setLayout() to change it. However, BorderLayout by itself won't allow you to put 10 different objects in it - just 5 at most (one per region). You probably want GridLayout or GridBagLayout.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!