Skip to content

gh-86726: Improve the structure of the tkinter reference#152109

Merged
serhiy-storchaka merged 1 commit into
python:mainfrom
serhiy-storchaka:tkinter-winfo-doc-intro
Jun 24, 2026
Merged

gh-86726: Improve the structure of the tkinter reference#152109
serhiy-storchaka merged 1 commit into
python:mainfrom
serhiy-storchaka:tkinter-winfo-doc-intro

Conversation

@serhiy-storchaka

@serhiy-storchaka serhiy-storchaka commented Jun 24, 2026

Copy link
Copy Markdown
Member

Several structural improvements to the tkinter module reference, all documentation-only.

Add short group intros before each cluster of Misc methods (the bind, event_, after, focus_, grab_, selection_, clipboard_, option_, busy_ and winfo_ prefixes), so each run of related methods is introduced by a sentence explaining what the prefix means.

Group the Tk and Toplevel classes in a new "Toplevel widgets" section, instead of documenting Tk in the middle of the "Tkinter modules" overview and leaving Toplevel dangling at the end of the base and mixin classes. Move the Tcl() factory function to the module-level functions section, add a reference to it from Tk, and document that Tk inherits from Misc and Wm.

Move the "File handlers" section into the reference, where its createfilehandler/deletefilehandler methods and READABLE/WRITABLE/EXCEPTION constants belong, instead of leaving it as a standalone section just before the reference. The cross-reference target is preserved.

Add short group intros before each cluster of Misc methods.
Group the Tk and Toplevel classes in a new "Toplevel widgets" section, move
the Tcl() function to the module-level functions, and move the "File
handlers" section into the reference.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@read-the-docs-community

Copy link
Copy Markdown

Documentation build overview

📚 cpython-previews | 🛠️ Build #33294830 | 📁 Comparing 8a40b58 against main (6c3da17)

  🔍 Preview build  

2 files changed
± library/tk.html
± library/tkinter.html

@serhiy-storchaka serhiy-storchaka added needs backport to 3.13 bugs and security fixes needs backport to 3.14 bugs and security fixes needs backport to 3.15 pre-release feature fixes, bugs and security fixes labels Jun 24, 2026
@serhiy-storchaka serhiy-storchaka merged commit c7faa69 into python:main Jun 24, 2026
42 checks passed
@github-project-automation github-project-automation Bot moved this from Todo to Done in Docs PRs Jun 24, 2026
@serhiy-storchaka serhiy-storchaka deleted the tkinter-winfo-doc-intro branch June 24, 2026 18:10
@miss-islington-app

Copy link
Copy Markdown

Thanks @serhiy-storchaka for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14, 3.15.
🐍🍒⛏🤖 I'm not a witch! I'm not a witch!

@miss-islington-app

Copy link
Copy Markdown

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.15 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker c7faa6936e17630ec26d4e0438ae9b95561b7151 3.15

@miss-islington-app

Copy link
Copy Markdown

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.14 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker c7faa6936e17630ec26d4e0438ae9b95561b7151 3.14

@miss-islington-app

Copy link
Copy Markdown

Sorry, @serhiy-storchaka, I could not cleanly backport this to 3.13 due to a conflict.
Please backport using cherry_picker on command line.

cherry_picker c7faa6936e17630ec26d4e0438ae9b95561b7151 3.13

@serhiy-storchaka serhiy-storchaka removed needs backport to 3.13 bugs and security fixes needs backport to 3.14 bugs and security fixes needs backport to 3.15 pre-release feature fixes, bugs and security fixes labels Jun 24, 2026
@serhiy-storchaka serhiy-storchaka removed their assignment Jun 24, 2026
serhiy-storchaka added a commit that referenced this pull request Jun 24, 2026
…52109 (GH-152111)

Add short group intros before each cluster of Misc methods.
Group the Tk and Toplevel classes in a new "Toplevel widgets" section, move
the Tcl() function to the module-level functions, and move the "File
handlers" section into the reference.
(cherry picked from commit c7faa69)

Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

docs Documentation in the Doc dir skip news

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

1 participant