Fix QCloseEvent, add Draw line, arc, rect, point and ellipse to QPainter.