def transform(qtbot, mocker): """Fixture to retrieve a clean Transform instance.""" pixmap = QPixmap(300, 300) current_pm = current_pixmap.CurrentPixmap() transform = imtransform.Transform(current_pm) current_pm.pixmap = transform.original = pixmap return transform
def __init__(self): super().__init__() self._current_pixmap = current_pixmap.CurrentPixmap() self._manipulated = False self.transform = imtransform.Transform(self._current_pixmap) self.manipulate = None self.transform.transformed.connect(self._change_current) api.modes.MANIPULATE.first_entered.connect(self._init_manipulate)
def __init__(self): super().__init__() self._pixmaps = Pixmaps() self.transform = imtransform.Transform(self) self.manipulate = immanipulate.Manipulator(self) self._path = "" imutils.new_image_opened.connect(self._on_new_image_opened) imutils.all_images_cleared.connect(self._on_images_cleared) imutils.image_changed.connect(self.reload) QCoreApplication.instance().aboutToQuit.connect(self._on_quit)
def __init__(self): super().__init__() self._pixmaps = Pixmaps() self.transform = imtransform.Transform(self) self.manipulate = None self._path = "" self._image_type = None api.signals.new_image_opened.connect(self._on_new_image_opened) api.signals.all_images_cleared.connect(self._on_images_cleared) api.signals.image_changed.connect(self.reload) api.modes.MANIPULATE.first_entered.connect(self._init_manipulate) QCoreApplication.instance().aboutToQuit.connect(self._on_quit)
def transform(qtbot): """Fixture to retrieve a clean Transform instance.""" transform.handler = MockHandler() # Keep as reference here due to weakref return imtransform.Transform(transform.handler)