Perhaps I should add, my experiments with Events has been a bit iffy so far,
this:
QObject * target
= parent
() ? parent
() : this;
QObject * target = parent() ? parent() : this;
QEvent * event = new QResizeEvent(QSize(w,h),size());
QApplication::postEvent (target, event);
To copy to clipboard, switch view to plain text mode
has no effect (parent is a QMainWindow), and this:
QApplication::postEvent (this, new QPaintEvent (QRect(0,0,width(),height())));
To copy to clipboard, switch view to plain text mode
Causes a "QPainter::begin: Widget painting can only begin as a result of a paintEvent" message to be printed.
Bookmarks