Skip to content

Commit 5acaad0

Browse files
bpo-45296: Clarify close, quit, and exit in IDLE (GH-30936) (GH-30944)
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 'exit()' mean 'close Shell'. If there are no other windows, this also exits IDLE. (cherry picked from commit fcde0bc) Co-authored-by: Terry Jan Reedy <[email protected]> Co-authored-by: Terry Jan Reedy <[email protected]>
1 parent c7af838 commit 5acaad0

File tree

4 files changed

+23
-15
lines changed

4 files changed

+23
-15
lines changed

Doc/library/idle.rst

+6-4
Original file line numberDiff line numberDiff line change
@@ -96,11 +96,13 @@ Save Copy As...
9696
Print Window
9797
Print the current window to the default printer.
9898

99-
Close
100-
Close the current window (ask to save if unsaved).
99+
Close Window
100+
Close the current window (if an unsaved editor, ask to save; if an unsaved
101+
Shell, ask to quit execution). Calling ``exit()`` or ``close()`` in the Shell
102+
window also closes Shell. If this is the only window, also exit IDLE.
101103

102-
Exit
103-
Close all windows and quit IDLE (ask to save unsaved windows).
104+
Exit IDLE
105+
Close all windows and quit IDLE (ask to save unsaved edit windows).
104106

105107
Edit menu (Shell and Editor)
106108
^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Lib/idlelib/help.html

+11-9
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<head>
66
<meta charset="utf-8" />
77
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
8-
<title>IDLE &#8212; Python 3.11.0a0 documentation</title>
8+
<title>IDLE &#8212; Python 3.11.0a4 documentation</title>
99
<link rel="stylesheet" href="../_static/pydoctheme.css" type="text/css" />
1010
<link rel="stylesheet" href="../_static/pygments.css" type="text/css" />
1111

@@ -18,7 +18,7 @@
1818
<script src="../_static/sidebar.js"></script>
1919

2020
<link rel="search" type="application/opensearchdescription+xml"
21-
title="Search within Python 3.11.0a0 documentation"
21+
title="Search within Python 3.11.0a4 documentation"
2222
href="../_static/opensearch.xml"/>
2323
<link rel="author" title="About these documents" href="../about.html" />
2424
<link rel="index" title="Index" href="../genindex.html" />
@@ -71,7 +71,7 @@ <h3>Navigation</h3>
7171

7272

7373
<li id="cpython-language-and-version">
74-
<a href="../index.html">3.11.0a0 Documentation</a> &#187;
74+
<a href="../index.html">3.11.0a4 Documentation</a> &#187;
7575
</li>
7676

7777
<li class="nav-item nav-item-1"><a href="index.html" >The Python Standard Library</a> &#187;</li>
@@ -163,9 +163,11 @@ <h3>File menu (Shell and Editor)<a class="headerlink" href="#file-menu-shell-and
163163
</dd>
164164
<dt>Print Window</dt><dd><p>Print the current window to the default printer.</p>
165165
</dd>
166-
<dt>Close</dt><dd><p>Close the current window (ask to save if unsaved).</p>
166+
<dt>Close Window</dt><dd><p>Close the current window (if an unsaved editor, ask to save; if an unsaved
167+
Shell, ask to quit execution). Calling <code class="docutils literal notranslate"><span class="pre">exit()</span></code> or <code class="docutils literal notranslate"><span class="pre">close()</span></code> in the Shell
168+
window also closes Shell. If this is the only window, also exit IDLE.</p>
167169
</dd>
168-
<dt>Exit</dt><dd><p>Close all windows and quit IDLE (ask to save unsaved windows).</p>
170+
<dt>Exit IDLE</dt><dd><p>Close all windows and quit IDLE (ask to save unsaved edit windows).</p>
169171
</dd>
170172
</dl>
171173
</div>
@@ -976,7 +978,7 @@ <h3>Navigation</h3>
976978

977979

978980
<li id="cpython-language-and-version">
979-
<a href="../index.html">3.11.0a0 Documentation</a> &#187;
981+
<a href="../index.html">3.11.0a4 Documentation</a> &#187;
980982
</li>
981983

982984
<li class="nav-item nav-item-1"><a href="index.html" >The Python Standard Library</a> &#187;</li>
@@ -1000,16 +1002,16 @@ <h3>Navigation</h3>
10001002
</ul>
10011003
</div>
10021004
<div class="footer">
1003-
&copy; <a href="../copyright.html">Copyright</a> 2001-2021, Python Software Foundation.
1005+
&copy; <a href="../copyright.html">Copyright</a> 2001-2022, Python Software Foundation.
10041006
<br />
10051007

10061008
The Python Software Foundation is a non-profit corporation.
10071009
<a href="https://www.python.org/psf/donations/">Please donate.</a>
10081010
<br />
10091011
<br />
10101012

1011-
Last updated on Sep 06, 2021.
1012-
<a href="https://docs.python.org/3/bugs.html">Found a bug</a>?
1013+
Last updated on Jan 26, 2022.
1014+
<a href="/bugs.html">Found a bug</a>?
10131015
<br />
10141016

10151017
Created using <a href="https://www.sphinx-doc.org/">Sphinx</a> 3.2.1.

Lib/idlelib/mainmenu.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -34,8 +34,8 @@
3434
None,
3535
('Prin_t Window', '<<print-window>>'),
3636
None,
37-
('_Close', '<<close-window>>'),
38-
('E_xit', '<<close-all-windows>>'),
37+
('_Close Window', '<<close-window>>'),
38+
('E_xit IDLE', '<<close-all-windows>>'),
3939
]),
4040

4141
('edit', [
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
Clarify close, quit, and exit in IDLE. In the File menu, 'Close' and 'Exit'
2+
are now 'Close Window' (the current one) and 'Exit' is now 'Exit IDLE'
3+
(by closing all windows). In Shell, 'quit()' and 'exit()' mean 'close Shell'.
4+
If there are no other windows, this also exits IDLE.

0 commit comments

Comments
 (0)