blob: ff8988c85e1ce0b08f515ab136f7061c2dadd2dc [file] [log] [blame]
Kurt B. Kaiser6fa09112003-01-14 22:06:11 +00001[See the end of this file for ** TIPS ** on using IDLE !!]
David Scherer7aced172000-08-15 01:13:23 +00002
3Click on the dotted line at the top of a menu to "tear it off": a
4separate window containing the menu is created.
5
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +00006File Menu:
David Scherer7aced172000-08-15 01:13:23 +00007
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +00008 New Window -- create a new editing window
David Scherer7aced172000-08-15 01:13:23 +00009 Open... -- open an existing file
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000010 Recent Files... -- open a list of recent files
11 Open Module... -- open an existing module (searches sys.path)
12 Class Browser -- show classes and methods in current file
13 Path Browser -- show sys.path directories, modules, classes
Kurt B. Kaiser1061e722003-01-04 01:43:53 +000014 and methods
David Scherer7aced172000-08-15 01:13:23 +000015 ---
16 Save -- save current window to the associated file (unsaved
17 windows have a * before and after the window title)
18
19 Save As... -- save current window to new file, which becomes
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000020 the associated file
David Scherer7aced172000-08-15 01:13:23 +000021 Save Copy As... -- save current window to different file
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000022 without changing the associated file
23 ---
24 Print Window -- print the current window
David Scherer7aced172000-08-15 01:13:23 +000025 ---
26 Close -- close current window (asks to save if unsaved)
27 Exit -- close all windows and quit IDLE (asks to save if unsaved)
28
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000029Edit Menu:
David Scherer7aced172000-08-15 01:13:23 +000030
31 Undo -- Undo last change to current window (max 1000 changes)
32 Redo -- Redo last undone change to current window
33 ---
34 Cut -- Copy selection into system-wide clipboard; then delete selection
35 Copy -- Copy selection into system-wide clipboard
36 Paste -- Insert system-wide clipboard into window
37 Select All -- Select the entire contents of the edit buffer
38 ---
39 Find... -- Open a search dialog box with many options
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000040 Find Again -- Repeat last search
41 Find Selection -- Search for the string in the selection
David Scherer7aced172000-08-15 01:13:23 +000042 Find in Files... -- Open a search dialog box for searching files
43 Replace... -- Open a search-and-replace dialog box
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000044 Go to Line -- Ask for a line number and show that line
45 Expand Word -- Expand the word you have typed to match another
46 word in the same buffer; repeat to get a different
47 expansion
48
49Format Menu (only in Edit window):
50
51 Indent Region -- Shift selected lines right 4 spaces
52 Dedent Region -- Shift selected lines left 4 spaces
53 Comment Out Region -- Insert ## in front of selected lines
54 Uncomment Region -- Remove leading # or ## from selected lines
55 Tabify Region -- Turns *leading* stretches of spaces into tabs
56 Untabify Region -- Turn *all* tabs into the right number of spaces
57 New Indent Width... -- Open dialog to change indent width
David Scherer7aced172000-08-15 01:13:23 +000058 Format Paragraph -- Reformat the current blank-line-separated paragraph
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000059
60Run Menu (only in Edit window):
61
62 Python Shell -- Open or wake up the Python shell window
David Scherer7aced172000-08-15 01:13:23 +000063 ---
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000064 Check Module -- Run a syntax check on the module
65 Run Script -- Execute the current file in the __main__ namespace
David Scherer7aced172000-08-15 01:13:23 +000066
Kurt B. Kaiser1061e722003-01-04 01:43:53 +000067Shell Menu (only in Shell window):
68
69 View Last Restart -- Scroll the shell window to the last restart
70 Restart Shell -- Restart the interpreter with a fresh environment
71 ---
72 Go to File/Line -- look around the insert point for a filename
73 and linenumber, open the file, and show the line
74 Debugger (toggle) -- Run commands in the shell under the debugger
75 Stack Viewer -- show the stack traceback of the last exception
76 Auto-open Stack Viewer (toggle) -- Open stack viewer on traceback
77
78Options Menu:
David Scherer7aced172000-08-15 01:13:23 +000079
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000080 Configure IDLE -- Open a configuration dialog. Fonts, indentation,
81 keybindings, and color themes may be altered.
Kurt B. Kaiser6fa09112003-01-14 22:06:11 +000082 Startup Preferences may be set, and Additional Help
83 Souces can be specified.
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000084 ---
85 Revert to Default Settings -- Restore original settings
86
87Windows Menu:
88
89 Zoom Height -- toggles the window between configured size
David Scherer7aced172000-08-15 01:13:23 +000090 and maximum height.
91 ---
92 The rest of this menu lists the names of all open windows;
93 select one to bring it to the foreground (deiconifying it if
94 necessary).
95
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000096Help Menu:
97
Kurt B. Kaiser6fa09112003-01-14 22:06:11 +000098 About IDLE -- Version, copyright, license, credits
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +000099 IDLE Readme -- Background discussion and change details
100 ---
Kurt B. Kaiser6fa09112003-01-14 22:06:11 +0000101 IDLE Help -- Display this file
102 Python Docs -- Access local Python documentation, if
103 installed. Otherwise, access www.python.org.
104 ---
105 (Additional Help Sources)
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +0000106
Kurt B. Kaiser6fa09112003-01-14 22:06:11 +0000107
108** TIPS **
109==========
110
111Additional Help Sources:
112
113 Windows users can Google on pythlp.chm and zopeshelf.chm to access help
114 files in the Windows help format. The Additional Help Sources feature
115 of the configuration GUI supports .chm, along with any other filetypes
116 supported by your browser. Supply a Menu Item title, and enter the
117 location in the Help File Path slot of the New Help Source dialog. Use
118 http:// and/or www. to identify external URLs, or download the file and
119 browse for its path on your machine using the Browse button.
120
121 All users can access the extensive sources of help, including
122 tutorials, available at www.python.org/doc. Selected URLs can be added
123 or removed from the Help menu at any time.
David Scherer7aced172000-08-15 01:13:23 +0000124
125Basic editing and navigation:
126
127 Backspace deletes to the left; DEL deletes to the right
128 Arrow keys and Page Up/Down to move around
129 Home/End go to begin/end of line
130 Control-Home/End go to begin/end of file
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +0000131 Some Emacs or standard Windows bindings may work.
132 Keybindings are selected in the Settings Dialog, look there.
David Scherer7aced172000-08-15 01:13:23 +0000133
134Automatic indentation:
135
136 After a block-opening statement, the next line is indented by
137 4 spaces (in the Python Shell window by one tab). After
138 certain keywords (break, return etc.) the next line is
139 dedented. In leading indentation, Backspace deletes up to 4
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +0000140 spaces if they are there. Tab inserts spaces (in the
141 Python Shell window one tab), number depends on Indent Width
142 See also the indent/dedent region commands in the edit menu.
David Scherer7aced172000-08-15 01:13:23 +0000143
144Python Shell window:
145
146 ^C interrupts executing command
147 ^D sends end-of-file; closes window if typed at >>> prompt
148
149 Command history:
150
151 Alt-p retrieves previous command matching what you have typed
152 Alt-n retrieves next
153 Return while on any previous command retrieves that command
154 Alt-/ (Expand word) is also useful here
155
156Syntax colors:
157
158 The coloring is applied in a background "thread", so you may
159 occasionally see uncolorized text. To change the color
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +0000160 scheme, use the Settings/Highlighting dialog.
David Scherer7aced172000-08-15 01:13:23 +0000161
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +0000162 Python default syntax colors:
David Scherer7aced172000-08-15 01:13:23 +0000163
164 Keywords orange
165 Strings green
166 Comments red
167 Definitions blue
168
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +0000169 Shell default colors:
David Scherer7aced172000-08-15 01:13:23 +0000170
171 Console output brown
172 stdout blue
173 stderr dark green
174 stdin black
175
176Other preferences:
177
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +0000178 The font preferences, keybinding, and startup preferences can
179 be changed using the Settings dialog.
David Scherer7aced172000-08-15 01:13:23 +0000180
181Command line usage:
Kurt B. Kaiser39c7b452002-12-11 04:42:39 +0000182
183 Enter idle -h at the command prompt to get a usage message.