Thanks for the ideas! I appreciate it.
aamer4yu, I have implemented your mousePressEvent idea, thanks!
tbcope, you said:
The painting should be done in your label or glwidget
I would like to futher this idea.
How exactly would I pass the paint event to the label?
Currently I have:
{
paintme.
drawLine(QLineF(10.0,
80.0,
90.0,
20.0));
}
void Planning::paintEvent(QPaintEvent *event)
{
QPainter paintme(this);
paintme.drawLine(QLineF(10.0, 80.0, 90.0, 20.0));
}
To copy to clipboard, switch view to plain text mode
I tried adding the following to the end of the paintEvent, but it doesn't seem to work:
QLabel::paintEvent(event);
To copy to clipboard, switch view to plain text mode
How exactly would I pass the paint operation to take place on the QLabel so that it appears on the pixmap?
Bookmarks