I made a class called ImageLabel which extends QLabel. I want it to keep the size ratio of the image that it is displaying no matter how stretched out it is. It works fine w
There is no facility built into QLabel to maintain the aspect ratio of the image. Since Qlabel probably has functionality that you don't need, you should subclass QWidget and override the paintEvent() to render the image the way you want.