public void move(int dx, int dy) {
        ((Rectangle) shape).x += dx;
        ((Rectangle) shape).y += dy;
        for (PathItem pi : this.getLines()) {
            pi.move(dx, dy);
        }
        updateCornerRects();
        canvas.repaint();
    }