Originally Posted by yogeshgokul At the time of scaling the image. You can use these options: Qt Code: Switch view Qt::KeepAspectRatioQt::KeepAspectRatioByExpanding Qt::KeepAspectRatio Qt::KeepAspectRatioByExpanding To copy to clipboard, switch view to plain text mode Whatever suits your requirement. So you propose to create a custom widget, re-implement paintEvent and draw a properly scaled image, right? Is there a way to do that via Designer without writing code - this is what I was thinking about.
Qt::KeepAspectRatioQt::KeepAspectRatioByExpanding
Qt::KeepAspectRatio Qt::KeepAspectRatioByExpanding
Originally Posted by psih128 So you propose to create a custom widget, re-implement paintEvent and draw a properly scaled image, right? Yes Subclass QLabel and scale the Pixmap properly in resizeEvent();
View Tag Cloud
Forum Rules
Bookmarks