Skip to content

Commit

Permalink
Reset start/stop needle sides when loading an image
Browse files Browse the repository at this point in the history
Fixes #732.
  • Loading branch information
jonathanperret authored and dl1com committed Dec 4, 2024
1 parent 5e781f1 commit 544245b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/main/python/main/ayab/engine/options.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,9 @@ def set_image_dimensions(self, width: int, height: int) -> None:
Updates the maximum value of the Start Row UI element.
"""
left_side = width // 2
self.ui.start_needle_color.setCurrentIndex(0) # orange
self.ui.start_needle_edit.setValue(left_side)
self.ui.stop_needle_color.setCurrentIndex(1) # green
self.ui.stop_needle_edit.setValue(width - left_side)
self.ui.start_row_edit.setMaximum(height)

Expand Down

0 comments on commit 544245b

Please sign in to comment.