Posts by Phrank • 35 points
2 posts
-
1
votes1
answer899
viewsQ: How to draw lines following the mouse movement?
I need a JPanel, that draws lines following the mouse pointer while it is dragged, and when released it needs to stop drawing. It turns out that whenever two or more lines are drawn in a row, they…
-
2
votes1
answer220
viewsQ: How to change Graphics2d objects off paintComponent
I wonder how to change the color of a drawRectangle() of Graphics2d java, out of the way @Override paintComponent(). It turns out that this change should be temporary, only when the mouse pointer…