-
Notifications
You must be signed in to change notification settings - Fork 7
Disable WF case buttons if Case Ignore
#291
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
Disable WF case buttons if Case Ignore
#291
Conversation
When Case Ignore is on, words that are ALL CAPS, Initial Caps, or MiXeD cASe aren't detected, which could confuse the user. Therefore disable those buttons when Case Ignore is on, and enable them when it's off. Display a tooltip to explain to the user if they are disabled.
✅ When setting "ignore case" the buttons are properly disabled, their labels are grayed out, and the tooltips are working. ✅ If you then uncheck "ignore case" the text labels on the buttons go back to normal, and the tooltips disappear. ❌ But, the buttons themselves are still disabled - for all 3 buttons I cannot use that function anymore, unless I close WF and open a new WF dialog. |
Confirmed. I didn't think to check this in my initial testing. In this round of testing, I tried manually re-running it, but as @tangledhelix says, only closing WF and re-starting it worked. |
Also confirmed (and embarrassed not to have noticed while testing) |
Unbind unbinds all when it should only unbind the function associated with the ID given. Work round it by getting all bindings, and only reattaching the ones we want.
I'm very hesitant to say it's a "python/tkinter/tk/tcl/etc" bug, but in this case it is: python/cpython#75666 So, slightly less embarrassment, and hopefully now fixed. Thanks @tangledhelix for spotting this. |
The others were hard to pronounce!
Is it supposed to default to All Words if you select "Ignore Case" while one of the case-sensitive options is selected? Right now, everything is deselected for me (macOS). Which I don't have a problem with, but just wanted to make sure that's the expected behavior. |
For me, it still shows ALL CAPS selected, even though it is disabled, and the list of words is empty. If you hover over it, it displays the tooltip, and if you turn Ignore Case off again, you get back the ALL CAPS words. I'm happy with that behaviour - is that different to what you see? |
... I did not expect that spinner graphic to be so large! 🤨 |
That's what I'm seeing now, too. I'm not sure what caused the button last selected not to be selected any longer the time I tried it earlier, but that's not what I'm seeing now.
Maybe not as obvious, but would it be possible to force the re-run button to change color as it does when you click on it? It's not quite as obvious on macOS with the default theme when the system is on dark mode as it is on light mode, but there is a difference. Or put an additional drop-shadow on the button while the function is working? (No, please not a spinner of that size! 🤣) |
I wonder if it would be better to implement a general "busy" state, like GG1 has, which changes the cursor to the busy cursor (whatever that is for your system) and then changes it back when it's done. That seems to be a fairly standard way to indicate that something is happening. Not in this PR of course - I'll add an issue. |
When Case Ignore is on, words that are ALL CAPS, Initial Caps, or MiXeD cASe aren't detected, which could
confuse the user. Therefore disable those buttons when Case Ignore is on, and enable them when it's off. Display a tooltip to explain to the user if they are disabled.
Fixes #289