I have QLabel on the form. I use it to show an image like this:
ui
->label
->setPixmap
(QPixmap::fromImage(image.
scaled(349,
228, Qt
::KeepAspectRatio, Qt
::FastTransformation)));
ui->label->adjustSize();
QString fileName = "image.jpg";
QImage image(fileName);
ui->label->setPixmap(QPixmap::fromImage(image.scaled(349,228, Qt::KeepAspectRatio, Qt::FastTransformation)));
ui->label->adjustSize();
To copy to clipboard, switch view to plain text mode
How can I paint with brush on my QLabel with mouse? For example, i press left mouse key, then dragging, it lefts brush'es line, then the results - on the QLabel.
Bookmarks