Fit QGraphisItem in view
问题 Is a method to fit any image in view (that I import in QPixmap) and keep aspect ratio>. I try many solution but non of those works. Also I don't not sure what I need to fit? QGraphicsScene in QGraphicsView? Or QPixmap in QGraphicsView? from PyQt5 import QtCore, QtGui, QtWidgets class GraphicsView(QtWidgets.QGraphicsView): def __init__(self, parent=None): super(GraphicsView, self).__init__(parent) scene = QtWidgets.QGraphicsScene() self.setScene(scene) if __name__ == "__main__": import sys app