-
-
Notifications
You must be signed in to change notification settings - Fork 30.9k
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
Change turtledemo button colors #88420
Comments
[Following up on #88409.] I don't like the current colors anyway, so I think we should change to something on white. I am thinking of green, red, and blue for Start, Stop, and Clear. |
One quick comment: one shouldn't assume what colors are being used on current macOS systems and a current Tk, like on macOS 11 Big Sur and Tk 8.6.11. The foreground and background colors can depend on what system appearance is selected by the user (System Preferences -> General -> Appearance: Light/Dark/Auto). Changing the system appearance to Dark causes the Turtle Demo buttons to have a darker background and so the white text labels are now quite visible. I don't know what the best solution is but it shouldn't be based on the assumption that the colors are fixed. |
I am going to disable color config on darwin (and hope it gets into b2). The default should always work. |
Ned, could you check the darwin osascript in turtledemo.__main__, lines 138-149 is current (both needed and correct)?
The one line could be an fstring now. |
I did a quick check and it looks like the code may not be needed on the latest macOS and Tk versions; however, I did not go back and check it on older systems and, in any case, it doesn't cause seem to cause any harm and it still does what it is supposed to do: ensure that the turtledemo process is the frontmost, active one regardless of what the OS or Tk may do. |
I also just did a quick test of PR 25448. The current version seems to have swapped one problem for another: now button labels are legible when the Light mode appearance is in effect but the labels blend into the button background when in Dark mode, the opposite of the current behavior. |
I presume you tested pr_26448. If default colors do not work, that is on tcl/tk. I suspect 8.6.11 is not prepared for dark theme. The underlying bug is ignoring the tk/user setting and deferring to the system for background only. In the meanwhile, I will try to set the forground to something at least readable on either background. Is the dark theme background black as opposed to dark something? |
Of course, I cannot set the background on my Mac, so I will test on Windows and let you verify on dark theme mac |
I picked a bluish green that works on both white and black on Windows. Test if you can and wish. |
@terryjreedy The issue seems to be solved. We can close the issue. |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: