From a9c0703f03d1aa1ec5984fc610ba50683c9ff4ff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?S=C3=A9bastien=20Miquel?= Date: Mon, 21 Sep 2026 16:10:01 +0200 Subject: [PATCH] unwiden shortcut --- copienator/commands/cutleft.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/copienator/commands/cutleft.py b/copienator/commands/cutleft.py index f9b122c..883a048 100644 --- a/copienator/commands/cutleft.py +++ b/copienator/commands/cutleft.py @@ -195,6 +195,7 @@ class ImageReviewer: self.root.bind("N", lambda _event: self.on_shift(2 * CROP_SHIFT_STEP)) self.root.bind("t", lambda _event: self.on_shift(-CROP_SHIFT_STEP)) self.root.bind("l", lambda _event: self.on_enlarge(CROP_WIDTH_STEP)) + self.root.bind("L", lambda _event: self.on_enlarge(-CROP_WIDTH_STEP)) self.root.bind("1", lambda _event: self.on_set_max_pages(1)) Thread(target=self.prefetch_worker, daemon=True).start() @@ -290,7 +291,7 @@ class ImageReviewer: f"Files: {schema['number_of_files']} | " f"Cols: {schema['columns_per_file']}\n" "Enter: Save and next | s: flag error and skip | n: +50 | N: +100 | t: -50 | " - "l: widen by 50 | 1: use full pages" + "l: widen by 50 | Shift+l: undo widening by 50 | 1: use full pages" ), fg="black", ) @@ -305,7 +306,7 @@ class ImageReviewer: def on_enlarge(self, amount: int) -> None: if self.is_processing: return - self.current_width_offset += amount + self.current_width_offset = max(0, self.current_width_offset + amount) print(f"Applying extra width: {self.current_width_offset}") self.trigger_processing(self.files[self.index], self.current_shift)