-
Notifications
You must be signed in to change notification settings - Fork 118
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
[crop/qt5] spinbox bugfix #212
base: master
Are you sure you want to change the base?
Conversation
I'm sorry for not responding here earlier. After my struggle with mplayerDelogo which led to 1b7ebce, I fear that Qt doesn't allow setting maximum for a spinbox dynamically while keeping up/down buttons auto-repeat working. Does auto-repeat still work for you in all spinboxes with this change? I think, minimum width and height should be enforced at parameter validation and other relevant locations in code, also beyond this filter. I just lack a vision how to design this properly at the moment. Last but not least, if a filter may reject input, it must implement a pass-through operation. |
Well, it doesn't work here either. I have only tested for up/down arrow keys, those works. |
I did a proof-of-concept on this, using PySide6. It seems that auto-repeat is only broken if you update the maximum of the current spinbox, while it's being changed. As long as you're careful to only update other spinboxes' maxima, but leave the current widget alone, auto-repeat works fine. And that should be sufficient, because changing any spinbox's value can't affect its own maximum value. That should remain static, whatever the current value is set to. Whenever the code was updating maximum values, it would've always been calling |
My proof-of-concept, if you want to try it yourself, is in ferdnyc/spinbox_test. Just clone it and run The "Box Totals:" values will be updated based on the spinbox values and maximum values. Auto-repeat on the spinbox arrows works unless "Update all spinboxes" is checked. |
Thanks, will look into that. |
-on change set spinbox maximums, to prevent inversion (bad UX)
-these maximums prevent to set output resolution lower than 8x8
-spinboxes get minimum width, to prevent jerkiness (introduced by setMaximum)