]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-46591: Make About IDLE doc link label clickable (GH-30251)
authorWes <5124946+wesinator@users.noreply.github.com>
Wed, 2 Feb 2022 01:20:23 +0000 (20:20 -0500)
committerGitHub <noreply@github.com>
Wed, 2 Feb 2022 01:20:23 +0000 (20:20 -0500)
Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
Lib/idlelib/NEWS.txt
Lib/idlelib/help_about.py
Lib/idlelib/idle_test/htest.py
Misc/NEWS.d/next/Library/2022-01-31-15-40-38.bpo-46591.prBD1M.rst [new file with mode: 0644]

index ed2b05ed662e824644e8e87b52c15389c7060646..34b2c08a92256684c576b66d8f8f519997a2500c 100644 (file)
@@ -4,6 +4,8 @@ Released on 2022-10-03
 =========================
 
 
+bpo-46591: Make the IDLE doc URL on the About IDLE dialog clickable.
+
 bpo-45296: Clarify close, quit, and exit in IDLE.  In the File menu,
 'Close' and 'Exit' are now 'Close Window' (the current one) and 'Exit'
 is now 'Exit IDLE' (by closing all windows).  In Shell, 'quit()' and
index 019aacbd0faa20711bb9a2617a1f5f9751304959..c59f49459980680f00497830f5c20f7b8ec47825 100644 (file)
@@ -3,6 +3,7 @@
 """
 import os
 import sys
+import webbrowser
 from platform import python_version, architecture
 
 from tkinter import Toplevel, Frame, Label, Button, PhotoImage
@@ -94,6 +95,7 @@ class AboutDialog(Toplevel):
                      f"{version[:version.rindex('.')]}/library/idle.html",
                      justify=LEFT, fg=self.fg, bg=self.bg)
         docs.grid(row=7, column=0, columnspan=2, sticky=W, padx=10, pady=0)
+        docs.bind("<Button-1>", lambda event: webbrowser.open(docs['text']))
 
         Frame(frame_background, borderwidth=1, relief=SUNKEN,
               height=2, bg=self.bg).grid(row=8, column=0, sticky=EW,
index 666ff4cb8485106640afd38014df66ab957b5322..d297f8aa0094ee9424bbc3f60ccc7d2eb0b6d2ef 100644 (file)
@@ -77,8 +77,8 @@ AboutDialog_spec = {
     'kwds': {'title': 'help_about test',
              '_htest': True,
              },
-    'msg': "Test every button. Ensure Python, TK and IDLE versions "
-           "are correctly displayed.\n [Close] to exit.",
+    'msg': "Click on URL to open in default browser.\n"
+           "Verify x.y.z versions and test each button, including Close.\n "
     }
 
 # TODO implement ^\; adding '<Control-Key-\\>' to function does not work.
diff --git a/Misc/NEWS.d/next/Library/2022-01-31-15-40-38.bpo-46591.prBD1M.rst b/Misc/NEWS.d/next/Library/2022-01-31-15-40-38.bpo-46591.prBD1M.rst
new file mode 100644 (file)
index 0000000..7785faa
--- /dev/null
@@ -0,0 +1 @@
+Make the IDLE doc URL on the About IDLE dialog clickable.
\ No newline at end of file