Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

Maximize JDesktopPane

Posted on 2006-06-25
3
Medium Priority
?
901 Views
Last Modified: 2012-08-13

How can I Maximize JDesktopPane.

Thank you
0
Comment
Question by:sree032397
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 14

Accepted Solution

by:
StillUnAware earned 2000 total points
ID: 16982157
You must set the correct container Layout. For example, if using JFrame, the default layout is BorderLayout, and if using JPanel, the default is FlowLayout, instead You can set it to BorderLayout too:

jPanel.setLayout(new BorderLayout());
jPanel.add(jDesktopPane);

see the docs on layouts:

http://java.sun.com/docs/books/tutorial/uiswing/layout/using.html

and BorderLayout
http://java.sun.com/docs/books/tutorial/uiswing/layout/border.html
http://java.sun.com/j2se/1.5.0/docs/api/java/awt/BorderLayout.html
0

Featured Post

The top UI technologies you need to be aware of

An important part of the job as a front-end developer is to stay up to date and in contact with new tools, trends and workflows. That’s why you cannot miss this upcoming webinar to explore the latest trends in UI technologies!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you’re thinking to yourself “That description sounds a lot like two people doing the work that one could accomplish,” you’re not alone.
What do responsible coders do? They don't take detrimental shortcuts. They do take reasonable security precautions, create important automation, implement sufficient logging, fix things they break, and care about users.
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …
Six Sigma Control Plans

670 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question