X Tutup
The Wayback Machine - https://web.archive.org/web/20240502115835/https://github.com/python/cpython/issues/86997
Skip to content
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

IDLE fix colors for MacOS dark mode #86997

Open
E-Paine mannequin opened this issue Jan 5, 2021 · 3 comments
Open

IDLE fix colors for MacOS dark mode #86997

E-Paine mannequin opened this issue Jan 5, 2021 · 3 comments
Assignees
Labels
3.8 only security fixes 3.9 only security fixes 3.10 only security fixes easy topic-IDLE type-bug An unexpected behavior, bug, or error

Comments

@E-Paine
Copy link
Mannequin

E-Paine mannequin commented Jan 5, 2021

BPO 42831
Nosy @terryjreedy, @taleinat, @E-Paine

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:

assignee = 'https://github.com/terryjreedy'
closed_at = None
created_at = <Date 2021-01-05.12:54:54.117>
labels = ['easy', 'type-bug', '3.8', '3.9', '3.10', 'expert-IDLE']
title = 'IDLE fix colours for MacOS dark mode'
updated_at = <Date 2021-05-28.20:14:35.351>
user = 'https://github.com/E-Paine'

bugs.python.org fields:

activity = <Date 2021-05-28.20:14:35.351>
actor = 'taleinat'
assignee = 'terry.reedy'
closed = False
closed_date = None
closer = None
components = ['IDLE']
creation = <Date 2021-01-05.12:54:54.117>
creator = 'epaine'
dependencies = []
files = []
hgrepos = []
issue_num = 42831
keywords = ['easy', 'newcomer friendly']
message_count = 3.0
messages = ['384391', '384416', '384420']
nosy_count = 3.0
nosy_names = ['terry.reedy', 'taleinat', 'epaine']
pr_nums = []
priority = 'normal'
resolution = None
stage = 'needs patch'
status = 'open'
superseder = None
type = 'behavior'
url = 'https://bugs.python.org/issue42831'
versions = ['Python 3.8', 'Python 3.9', 'Python 3.10']

@E-Paine
Copy link
Mannequin Author

E-Paine mannequin commented Jan 5, 2021

Currently IDLE, in some places, uses predefined colours which assume it is in light mode. However, on the new Universal2 installers (I tested using 3.10.0a4) this causes issues, where this can no longer be assumed.

Taking the "About IDLE" dialogue as an example, it appears in a light theme and most notably makes button text very hard to read (as this is changed to white). I propose, on macOS systems running Tk >=8.6.10, we try to switch these colours to the system colours described in https://github.com/tcltk/tk/blob/main/macosx/README (IMO, we would test colour availability and catch a TclError rather than specifying conditions ourselves). For the about dialogue I think we would, for example, replace #bbbbbb with one of the systemWindowBackgroundColors.

@E-Paine E-Paine mannequin added 3.8 only security fixes 3.9 only security fixes 3.10 only security fixes labels Jan 5, 2021
@E-Paine E-Paine mannequin assigned terryjreedy Jan 5, 2021
@E-Paine E-Paine mannequin added topic-IDLE 3.8 only security fixes 3.9 only security fixes 3.10 only security fixes labels Jan 5, 2021
@E-Paine E-Paine mannequin assigned terryjreedy Jan 5, 2021
@E-Paine E-Paine mannequin added the topic-IDLE label Jan 5, 2021
@terryjreedy
Copy link
Member

terryjreedy commented Jan 5, 2021

This might be related to #52197, about IDLE and KDE/GTK dark themes.

In general, IDLE only controls colors for Shell and editor windows, leaving dialogs to system default. This appears to be true for the settings and search dialogs. 'About' is unusual in having some colors specified. I had nothing to do with that. Would it work to just remove those specifications? Otherwise, every widget should specify both foreground and background color.

@E-Paine
Copy link
Mannequin Author

E-Paine mannequin commented Jan 5, 2021

I have also done a grep and believe the other affected parts from the user's perspective are the debugger (I haven't checked if Mark's version also suffers), the help dialog and hover tip (e.g. over the squeezer button).

Would it work to just remove those specifications?

Almost certainly for the about dialog, though we would probably need to explicitly give the foreground colour for others (similar to what you did in PR 12262, I think)

@taleinat taleinat added easy type-bug An unexpected behavior, bug, or error labels May 28, 2021
@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
@terryjreedy terryjreedy changed the title IDLE fix colours for MacOS dark mode IDLE fix colors for MacOS dark mode Oct 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.8 only security fixes 3.9 only security fixes 3.10 only security fixes easy topic-IDLE type-bug An unexpected behavior, bug, or error
Projects
Status: No status
Development

No branches or pull requests

2 participants
X Tutup