-
Notifications
You must be signed in to change notification settings - Fork 12
Stage limits popup #1116
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Stage limits popup #1116
Conversation
Populating the stage limits controller. Currently the menu and the popup are opposite of each other. Also the updated values aren't reflected in the configuration.yaml file.
Updated MenuController and StageLimitsController to ensure stage limits state is consistently reflected in both the main menu and the stage limits popup. Added logic to update the popup's checkbox when toggling limits from the menu, and improved event handling for enabling/disabling limits from the popup.
Renamed StageLimitsController and StageLimitsPopup to AdvancedStageParametersController and AdvancedStageParametersPopup, respectively. Updated all references and improved UI to include microscope selection and enhanced layout. Added logging and refactored controller logic for better maintainability.
Introduces detection of NI galvo (analog) stage in configuration and exposes it in the advanced stage parameters popup. Adds per-axis flip flags and offset controls to the advanced stage parameters UI, updates controller logic to handle these new parameters, and improves code clarity and typing. Also updates menu and main warning message for conciseness.
Refactors the advanced stage parameters popup and its controller to improve microscope switching, configuration management, and widget handling. Removes NI Galvo stage logic from the popup, centralizes configuration updates, adds dynamic widget reconfiguration, and streamlines the saving and updating of stage parameters. Also adds debug print statements and improves code organization for maintainability.
Improves synchronization between UI and configuration for advanced stage parameters, ensuring changes are saved and reflected immediately. Adds update_configuration method, refactors saving and updating logic, and enhances widget trace setup. Also updates popup UI for better clarity and usability.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces a new "Advanced Stage Parameters" popup window that allows users to adjust stage parameters (limits, offsets, and flip flags) directly from within the microscope software interface, eliminating the need to close the application, manually edit configuration files, and restart.
Key changes include:
- Implementation of a comprehensive stage parameters popup with real-time configuration updates
- Addition of stage limits control integration with the existing menu system
- Code formatting improvements and cleanup across multiple files
Reviewed Changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 5 comments.
Show a summary per file
File | Description |
---|---|
stages_advanced_popup.py |
New popup view class for displaying and editing stage parameters including limits, offsets, and flip flags |
stages_advanced.py |
New controller class handling stage parameter updates, configuration saving, and microscope switching |
menus.py |
Integration of the new popup into the stage control menu and synchronization with existing stage limits functionality |
__init__.py |
Registration of the new controller in the sub-controllers module |
configuration_controller.py |
Enhanced configuration management with update methods and analog stage detection |
channels_tab.py |
Code formatting improvements for better readability |
stages.py |
Minor formatting and whitespace cleanup |
main.py |
Simplified warning message for non-Windows platforms |
config.py |
Code formatting improvements and cleanup |
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## develop #1116 +/- ##
===========================================
- Coverage 54.24% 53.87% -0.37%
===========================================
Files 186 190 +4
Lines 21420 21681 +261
===========================================
+ Hits 11619 11681 +62
- Misses 9801 10000 +199
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Introduces support for stage offsets in the configuration controller and advanced stage parameters popup. Updates type hints and refactors related methods to handle offsets, ensuring the view and controller can display and update stage offset values alongside limits and flip flags.
Add a new popup that allows us to adjust stage parameters from within the microscope software, rather than having to close it, modify the configuration file, and then restart it.