painting objects on a frame
Hello!
I wrote a desktop application in Java. When I run the app sometimes happens that all the objects aren't shown on the frame. If I move with the mose over positions where the not showing objects must be located they suddenly appear. How can I fix this problem?
I have jre 1.6 installed and all availible updates.
Thanks!
# 2
Its probably because you add components to the frame AFTER the frame is visible. So add all your components to the content pane first before making the frame visible.
If during normal program execution you dynamically add components to a visible panel then you would use, panel.revalidate().
> repaint() or update() after drawing?
Do not use update(), that is for a LAF change.