Learn PythonWin Shortcuts for Windows
General Shortcuts
| Action |
PythonWin Shortcut Keys |
| Reformat the current paragraph/comment block |
Alt + Q |
| Toggle view whitespace |
Ctrl + W |
| Expand the word at the cursor Pressing the key again expands to the next match |
Alt + / |
| Auto-expand the attribute |
. |
| Toggle focus to/from the interactive window |
Alt + I |
Builtin hotkeys Shortcuts
| Action |
PythonWin Shortcut keys |
| Zoom-in for the current window |
Ctrl + + |
| Zoom-out for the current window |
Ctrl + – |
| Delete the word to the left of the cursor |
Ctrl + Backspace |
| Undo |
Ctrl + Z |
| Redo |
Ctrl + Y |
| Cut |
Ctrl + X |
| Copy |
Ctrl + C |
| Paste |
Ctrl + V |
| Select All |
Ctrl + A |
| Delete the current line |
Ctrl + Shift + L |
| Transpose (swap) the current line with the line above |
Ctrl + T |
| Convert the selection to lowercase |
Ctrl + U |
| Convert the selection to upper case |
Ctrl + Shift + U |
Editor Shortcuts
| Action |
PythonWin Shortcuts |
| Move to the next bookmark |
F2 |
| Add or remove a bookmark on the current line |
Ctrl + F2 |
| Prompt for and go a specific line number |
Ctrl + G |
| Adds a simple comment banner at the current location |
Alt + B |
| Uncomment the selected region |
Shift + Alt + 3 |
| Block comment on the selected region |
Alt + 3 |
| Uncomment the selected region (IDLE default keystroke) |
Alt + 4 |
| Tabify the selected region |
Alt + 5 |
| Untabify the selected region |
Alt + 6 |
| Remove the selected region or one character or indent to the left |
Backspace |
| Toggle the use of tabs for the current file (after confirmation) |
Ctrl + T |
| Change the indent width for the current file |
Alt + U |
| Insert a newline and indent |
Enter |
| Insert an indent, perform a block indent if a selection exists, or accept an attribute selection |
Tab |
| Block dedent the selection |
Shift + Tab |
| Toggle view when editor splitter is open |
F6 |
| If the current line is a collapsed fold, expand it (see Folding) |
+ |
| Expand all folds in the current file (see Folding ) |
Alt + + |
| If the current line is an expanded fold, collapse it (see Folding) |
– |
| Collapse all folds in the current file regardless of how deep the fold becomes (see Folding) |
Alt + – |
| Expand or collapse all top-level folds in the current file |
* |
Debugger Shortcuts
| Action |
PythonWin Shortcuts |
| Toggle breakpoint |
F9 |
| Run (ie, go) |
F5 |
| Stop debugging |
Shift + F5 |
| Single step into functions |
F11 |
| Step over functions |
F10 |
| Step out of the current function |
Shift + F11 |
Interactive Shortcuts
| Action |
PythonWin Shortcuts |
| Recall the previous command in the history list |
Ctrl + Up Arrow Key |
| Recall the next command in the history list |
Ctrl + Down Arrow Key |
READ NEXT: