Reputation: 493
How to render JPanel which contains the child components and that don't exist as part of the visible containment hierarchy (i.e. panel has no parent)?
Method SwingUtilities.paintComponent()
render only panel without the child components.
And how to handle mouse events by this panel?
Upvotes: 1
Views: 262
Reputation: 109823
Method SwingUtilities.paintComponent() renper only panel without the child components.
have look at paintChildren, paintComponents, depends of code,
I'd woudn't be to use paintComponents()
without important reason and good knowledge about Painting in Swing
Upvotes: 1