[ocrfeeder] Fix image preview
- From: Joaquim Rocha <jrocha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [ocrfeeder] Fix image preview
- Date: Sat, 4 Jan 2020 21:17:33 +0000 (UTC)
commit 668fbc1a3092b7fa87bfabfbf3fb9437f90f4e47
Author: scx <scx mail gmail com>
Date: Sun Jan 27 16:23:29 2019 +0100
Fix image preview
src/ocrfeeder/studio/widgetModeler.py | 6 ++++++
1 file changed, 6 insertions(+)
---
diff --git a/src/ocrfeeder/studio/widgetModeler.py b/src/ocrfeeder/studio/widgetModeler.py
index d2b0f1b..22d1cbd 100644
--- a/src/ocrfeeder/studio/widgetModeler.py
+++ b/src/ocrfeeder/studio/widgetModeler.py
@@ -250,6 +250,9 @@ class ImageReviewer(Gtk.Paned):
debug(exception.message)
return
self.selectable_boxes_area.setBackgroundImage(self.path_to_image)
+ self.editor.updateImage(self.image_pixbuf)
+ if self.editor.box:
+ self.editor.update(self.editor.box)
def updateBoxesColors(self):
self.editor.updateBoxColor()
@@ -1045,6 +1048,9 @@ class Editor:
self.__connectDataBoxSignals()
self.__updateBoxColor(None, self.data_box.type)
+ def updateImage(self, pixbuf):
+ self.pixbuf = pixbuf
+
def __connectDataBoxSignals(self):
handler_id = self.data_box.connect('changed_x', self.__updateEditorX)
self.__connected_signal_handles_list.append(handler_id)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]