Skip to content

Bugfix/popup behind logo#28

Open
ccabello99 wants to merge 2 commits intoPyMoDAQ:mainfrom
ccabello99:bugfix/popup-behind-logo
Open

Bugfix/popup behind logo#28
ccabello99 wants to merge 2 commits intoPyMoDAQ:mainfrom
ccabello99:bugfix/popup-behind-logo

Conversation

@ccabello99
Copy link
Contributor

My colleague pointed out a bug regarding the new pop-up window for the creation of default config files. If you had never created a config file, and you create a dashboard preset with a Basler set up to auto-initialize, then PyMoDAQ will hang with just the logo showing. It turns out the pop-up window was being hidden behind the PyMoDAQ logo.

This was easily fixed in Windows by adding the appropriate flag for the window to be "top-most." In Linux, this is another issue. Any attempt in dealing with this behavior would regularly lead to segfaults. It seems to be a conflict with the re-painting of the PyMoDAQ logo during the dashboard initialization and the pop-up window, which is blocking. In fact, it is because we are creating this window from a non-GUI thread. This is tolerated in Windows since the pop-up creation does not touch Qt. However, there is no straightforward solution to this issue at the plugin level for Linux. Therefore, I opted to have the config file created by default if none exists for Linux users, with no pop-up windows.

Let me know what you guys think.

@BenediktBurger
Copy link
Collaborator

Is there a special reason why you delete the daq_2Dviewer_BaslerWithLECO.py file?

For the rest of the PR, someone else has to take a look.

@ccabello99
Copy link
Contributor Author

Hello @BenediktBurger

I made the judgement that the way that it was written was a bit too specific to the needs of our lab group and the way we were using LECO in our global DAQ scheme. I would like to include it again, but it should be rewritten so as to be generalized first.

@rgeneaux
Copy link
Collaborator

rgeneaux commented Mar 9, 2026

Hi Christian, good catch (even though, which kind of madman runs dashboards without trying a daq_viewer first??)
This looks good to merge right away, or do you want us to test it as well?

@ccabello99
Copy link
Contributor Author

Indeed, I had not imagined anyone creating a dashboard before testing the camera with a daq_viewer :P
Nevertheless, I'm glad he pointed it out because it's useful if you know the plugin works generally for you, but you're just creating/changing a dashboard preset to use a different camera model. The end result is more user-friendly.

The patch works for me in a fresh environment with the latest PyMoDAQ release (on Python 3.11), so I would say it is fine to merge. Of course, feel free to test it yourself if you'd like to make sure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants