Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit a96f036

Browse files
bpo-37748: Re-order the Run menu. (GH-15115)
Put the most common choice, Run Module, at the top. (cherry picked from commit 1407029) Co-authored-by: Terry Jan Reedy <[email protected]>
1 parent a2ea944 commit a96f036

File tree

5 files changed

+46
-39
lines changed

5 files changed

+46
-39
lines changed

Doc/library/idle.rst

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -207,20 +207,6 @@ Strip trailing whitespace
207207
Run menu (Editor window only)
208208
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
209209

210-
.. _python-shell:
211-
212-
Python Shell
213-
Open or wake up the Python Shell window.
214-
215-
.. _check-module:
216-
217-
Check Module
218-
Check the syntax of the module currently open in the Editor window. If the
219-
module has not been saved IDLE will either prompt the user to save or
220-
autosave, as selected in the General tab of the Idle Settings dialog. If
221-
there is a syntax error, the approximate location is indicated in the
222-
Editor window.
223-
224210
.. _run-module:
225211

226212
Run Module
@@ -239,6 +225,20 @@ Run... Customized
239225
settings. *Command Line Arguments* extend :data:`sys.argv` as if passed
240226
on a command line. The module can be run in the Shell without restarting.
241227

228+
.. _check-module:
229+
230+
Check Module
231+
Check the syntax of the module currently open in the Editor window. If the
232+
module has not been saved IDLE will either prompt the user to save or
233+
autosave, as selected in the General tab of the Idle Settings dialog. If
234+
there is a syntax error, the approximate location is indicated in the
235+
Editor window.
236+
237+
.. _python-shell:
238+
239+
Python Shell
240+
Open or wake up the Python Shell window.
241+
242242

243243
Shell menu (Shell window only)
244244
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
@@ -295,8 +295,8 @@ Configure IDLE
295295
menu. For more details, see
296296
:ref:`Setting preferences <preferences>` under Help and preferences.
297297

298-
Most configuration options apply to all windows or all future windows.
299-
The option items below only apply to the active window.
298+
Most configuration options apply to all windows or all future windows.
299+
The option items below only apply to the active window.
300300

301301
Show/Hide Code Context (Editor Window only)
302302
Open a pane at the top of the edit window which shows the block context

Lib/idlelib/NEWS.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@ Released on 2019-09-30?
33
======================================
44

55

6+
bpo-37748: Reorder the Run menu. Put the most common choice,
7+
Run Module, at the top.
8+
69
bpo-37692: Improve highlight config sample with example shell
710
interaction and better labels for shell elements.
811

Lib/idlelib/help.html

Lines changed: 24 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -210,16 +210,6 @@ <h3>Edit menu (Shell and Editor)<a class="headerlink" href="#edit-menu-shell-and
210210
</div>
211211
<div class="section" id="run-menu-editor-window-only">
212212
<span id="index-2"></span><h3>Run menu (Editor window only)<a class="headerlink" href="#run-menu-editor-window-only" title="Permalink to this headline"></a></h3>
213-
<dl class="docutils" id="python-shell">
214-
<dt>Python Shell</dt><dd>Open or wake up the Python Shell window.</dd>
215-
</dl>
216-
<dl class="docutils" id="check-module">
217-
<dt>Check Module</dt><dd>Check the syntax of the module currently open in the Editor window. If the
218-
module has not been saved IDLE will either prompt the user to save or
219-
autosave, as selected in the General tab of the Idle Settings dialog. If
220-
there is a syntax error, the approximate location is indicated in the
221-
Editor window.</dd>
222-
</dl>
223213
<dl class="docutils" id="run-module">
224214
<dt>Run Module</dt><dd>Do <a class="reference internal" href="#check-module"><span class="std std-ref">Check Module</span></a>. If no error, restart the shell to clean the
225215
environment, then execute the module. Output is displayed in the Shell
@@ -234,6 +224,16 @@ <h3>Edit menu (Shell and Editor)<a class="headerlink" href="#edit-menu-shell-and
234224
settings. <em>Command Line Arguments</em> extend <a class="reference internal" href="sys.html#sys.argv" title="sys.argv"><code class="xref py py-data docutils literal notranslate"><span class="pre">sys.argv</span></code></a> as if passed
235225
on a command line. The module can be run in the Shell without restarting.</dd>
236226
</dl>
227+
<dl class="docutils" id="check-module">
228+
<dt>Check Module</dt><dd>Check the syntax of the module currently open in the Editor window. If the
229+
module has not been saved IDLE will either prompt the user to save or
230+
autosave, as selected in the General tab of the Idle Settings dialog. If
231+
there is a syntax error, the approximate location is indicated in the
232+
Editor window.</dd>
233+
</dl>
234+
<dl class="docutils" id="python-shell">
235+
<dt>Python Shell</dt><dd>Open or wake up the Python Shell window.</dd>
236+
</dl>
237237
</div>
238238
<div class="section" id="shell-menu-shell-window-only">
239239
<h3>Shell menu (Shell window only)<a class="headerlink" href="#shell-menu-shell-window-only" title="Permalink to this headline"></a></h3>
@@ -268,23 +268,26 @@ <h3>Options menu (Shell and Editor)<a class="headerlink" href="#options-menu-she
268268
<dl class="docutils">
269269
<dt>Configure IDLE</dt><dd>Open a configuration dialog and change preferences for the following:
270270
fonts, indentation, keybindings, text color themes, startup windows and
271-
size, additional help sources, and extensions. On macOS, open the
271+
size, additional help sources, and extensions. On macOS, open the
272272
configuration dialog by selecting Preferences in the application
273-
menu. For more, see
274-
<a class="reference internal" href="#preferences"><span class="std std-ref">Setting preferences</span></a> under Help and preferences.
275-
Most configuration options apply to all windows or all future windows.
276-
The option items below only apply to the active window.</dd>
273+
menu. For more details, see
274+
<a class="reference internal" href="#preferences"><span class="std std-ref">Setting preferences</span></a> under Help and preferences.</dd>
275+
</dl>
276+
<p>Most configuration options apply to all windows or all future windows.
277+
The option items below only apply to the active window.</p>
278+
<dl class="docutils">
277279
<dt>Show/Hide Code Context (Editor Window only)</dt><dd>Open a pane at the top of the edit window which shows the block context
278280
of the code which has scrolled above the top of the window. See
279-
<a class="reference internal" href="#code-context"><span class="std std-ref">Code Context</span></a> in the Editing and Navigation section below.</dd>
280-
<dt>Line Numbers (Editor Window only)</dt><dd>Open a column to the left of the edit window which shows the linenumber
281-
of each line of text. The default is off unless configured on
282-
(see <a class="reference internal" href="#preferences"><span class="std std-ref">Setting preferences</span></a>).</dd>
281+
<a class="reference internal" href="#code-context"><span class="std std-ref">Code Context</span></a> in the Editing and Navigation section
282+
below.</dd>
283+
<dt>Show/Hide Line Numbers (Editor Window only)</dt><dd>Open a column to the left of the edit window which shows the number
284+
of each line of text. The default is off, which may be changed in the
285+
preferences (see <a class="reference internal" href="#preferences"><span class="std std-ref">Setting preferences</span></a>).</dd>
283286
<dt>Zoom/Restore Height</dt><dd>Toggles the window between normal size and maximum height. The initial size
284287
defaults to 40 lines by 80 chars unless changed on the General tab of the
285288
Configure IDLE dialog. The maximum height for a screen is determined by
286289
momentarily maximizing a window the first time one is zoomed on the screen.
287-
Changing screen settings may invalidate the saved height. This toogle has
290+
Changing screen settings may invalidate the saved height. This toggle has
288291
no effect when a window is maximized.</dd>
289292
</dl>
290293
</div>
@@ -900,7 +903,7 @@ <h3>Navigation</h3>
900903
<br />
901904
<br />
902905

903-
Last updated on Jul 23, 2019.
906+
Last updated on Aug 04, 2019.
904907
<a href="https://docs.python.org/3/bugs.html">Found a bug</a>?
905908
<br />
906909

Lib/idlelib/mainmenu.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,10 +73,10 @@
7373
]),
7474

7575
('run', [
76-
('Python Shell', '<<open-python-shell>>'),
77-
('C_heck Module', '<<check-module>>'),
7876
('R_un Module', '<<run-module>>'),
7977
('Run... _Customized', '<<run-custom>>'),
78+
('C_heck Module', '<<check-module>>'),
79+
('Python Shell', '<<open-python-shell>>'),
8080
]),
8181

8282
('shell', [
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Reorder the Run menu. Put the most common choice, Run Module, at the top.

0 commit comments

Comments
 (0)