| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
…ction dialog The FontChooser class wraps the "tk fontchooser" command. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Documentation build overview32 files changed · + 2 added · ± 30 modified + Added ± Modified |
Sorry, something went wrong.
…ts=0 On macOS the native dialog stores the -font option as a resolved font description rather than the font name, and with wantobjects=0 Tcl returns strings instead of integers. Compare the actual font attributes and coerce the size to an integer. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Take the configuration options via **options and forward them to configure(), like SysTrayIcon, instead of enumerating each option in the constructor signature. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
| Back | FazBrowse Home | New Git URL |
Add the tkinter.fontchooser module, providing the FontChooser class as an interface to the native font selection dialog (the tk fontchooser command, available since Tk 8.6).
The dialog is modal on Windows but modeless on X11 and macOS, so FontChooser mirrors the underlying API instead of forcing a uniform modal behavior: show() may return immediately, and the selected font is delivered to the command callback (as a tkinter.font.Font object) together with the <<TkFontchooserVisibility>> and <<TkFontchooserFontChanged>> virtual events, rather than being returned.
FontChooser(master=None, *, parent=None, title=None, font=None, command=None) supports configure()/config(), cget(), show() and hide(). The options are parent, title, font, command and the read-only visible.
The tests require a GUI; the interactive show()/hide() part runs only on X11.