Drawing a JPanel to a BufferedImage, unexpected results
I'm building a node-based editor. Effectively it's Swing components on a giant carpet, connected with lines to denote relationships and flow of data. To achieve this I have my VisibleFrame with my Donatello JPanel that does the custom rendering. Donatello gets the Swing component of items in the view area, and then draws it like this:
Somehow Donatello is showing panel twice - once at my desired position and once in the top left corner. But I'm never connecting panel to Donatello, or frame to Donatello, so I'm not sure how this is possible. If I comment out
panel.paint(g2d)
both disappear. Anyone have a hint for me?3 Replies
⌛
This post has been reserved for your question.
Hey @i-make-robots! Please useTIP: Narrow down your issue to simple and precise questions to maximize the chance that others will reply in here./close
or theClose Post
button above when your problem is solved. Please remember to follow the help guidelines. This post will be automatically marked as dormant after 300 minutes of inactivity.
💤
Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived.
If your question was not answered yet, feel free to re-open this post or create a new one.
In case your post is not getting any attention, you can try to use /help ping
.
Warning: abusing this will result in moderative actions taken against you.
what the heck
💤
Post marked as dormant
This post has been inactive for over 300 minutes, thus, it has been archived.
If your question was not answered yet, feel free to re-open this post or create a new one.
In case your post is not getting any attention, you can try to use /help ping
.
Warning: abusing this will result in moderative actions taken against you.