wood burning stoves 2.0*
The moose likes Swing / AWT / SWT and the fly likes java repaint the frame or the panel? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "java repaint the frame or the panel?" Watch "java repaint the frame or the panel?" New topic
Author

java repaint the frame or the panel?

Anu Bhagat
Ranch Hand

Joined: Jun 20, 2008
Posts: 64
I am stuck on the repaint issue.

Here is the description of the problem

I have a myFrame which extends from JFrame,
I have myPanel (JPanel) and I add this to myFrame,

I then make few components and add them to myPanel

I move these components around in myPanel.. now I set a new size of myPanel.

I repaint myPanel. My components appear fine but myPanel does not resize to the new size that I set above.

This is done in a large application so I don not have code to provide.

I am really stuck on this problem, and would deeply appreciate any help.

Thanks in advance..

Anu

SCJP5.0, SCJA
Darryl Burke
Bartender

Joined: May 03, 2008
Posts: 4523
    
    5

Learn to use layout managers, and use them correctly.


luck, db
There are no new questions, but there may be new answers.
Anu Bhagat
Ranch Hand

Joined: Jun 20, 2008
Posts: 64
I solved it. It was a simple oversight on my part. Thanks for listening to me.

Anu
 
wood burning stoves
 
subject: java repaint the frame or the panel?
 
Similar Threads
Problem with Adding JScrollPane to JPanel!
Do certain events make calls to repaint redundant? (Part 2)
Blank Frame or Panel
Adding JPanel to JFrame
Sub JPanel Size