Win a copy of Cross-Platform Desktop Applications: Using Node, Electron, and NW.js this week in the JavaScript forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Automatic resizing of a JPanel in a JFrame  RSS feed

 
Sarra Sakka
Ranch Hand
Posts: 283
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I have created a JFrame that contains 3 JPanel.
My problem is, when i clicked in the bouton to expand the Frame,the 3 JPanel are fixed and do not expanded with the Jframe.
Would you tell me how can i solve this problem and thanks
 
Paul Clapham
Sheriff
Posts: 22374
42
Eclipse IDE Firefox Browser MySQL Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The short answer is you should use layout managers which allow that to happen (which is almost all layout managers). The long answer depends on the actual code you wrote to combine those JPanels into the JFrame -- so posting an SSCCE would be helpful.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!