[issue27309] Visual Styles support to tk/tkinter file and message dialogs

Terry J. Reedy report at bugs.python.org
Mon Jun 20 16:28:38 EDT 2016


Terry J. Reedy added the comment:

Pat, thank you for the explanation, xml, and link.  I was a bit confused by the overlapping yet different meanings of 'ttk theme' and 'Windows theme'.

For 3.6, I am converting IDLE to use ttk widgets.  From the example on the SO page, which links to https://i.stack.imgur.com/36MnO.png, the new Windows common controls better fit the default ttk theme on Windows.  However, for the same reason, the old set better fits standard tk widgets.  My impression from Stackoverflow tkinter questions is that most beginers start with tk widgets only.

Therefore, using the new set should not be forced on all Windows tkinter users.  Tkinter would need to be enhanced to optionally tell tk to use the new set.  I don't know if this is possible or how it would be done.  I leave this to Serhiy.

For an example, open IDLE on Windows with 3.6.0a2 or before.  Select Options => Configure IDLE => Highlighting.  Click [Save as New Custom Theme] to bring up a constructed entry box.  Without entering anything, click [Ok].  The commondialog messagebox error popup has an [Ok] button with a similar relief.

IDLE does not here use the commondialog entry messagebox because these disappear as soon as [Ok] is clicked, before error checking.  For an annoying example, select File => Open Module (Alt-m) and enter something that is not exactly 'idlelib.configdialog' (or 'idlelib.configDialog' before 3.6.0a2).  After dismissing the error box, one has to begin over.  I plan to replace with a custom validating entry popup.

> On X Windows Tk provides all these dialogs itself and so they use Tk widgets (or ttk widgets in more recent versions).

I wish these were available, at least as an option, on all systems.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue27309>
_______________________________________


More information about the Python-bugs-list mailing list