(Graphics g, float x, float y, float w, float h)
| 20 | } |
| 21 | |
| 22 | public void draw(Graphics g, float x, float y, float w, float h) { |
| 23 | x -= thickness; |
| 24 | y -= thickness; |
| 25 | w += 2 * thickness; |
| 26 | h += 2 * thickness; |
| 27 | g.fillRect(color, x, y, w, h); //draw filled rectangle behind object |
| 28 | } |
| 29 | } |