Use QWidget instead of QPainter