diff options
author | Guido van Rossum <guido@python.org> | 1998-10-12 23:55:10 (GMT) |
---|---|---|
committer | Guido van Rossum <guido@python.org> | 1998-10-12 23:55:10 (GMT) |
commit | 219ffde846304915e173bd99833e30d012a58b82 (patch) | |
tree | d99f7d67a3f142db0de727dfb5179d00c1bca657 /Tools | |
parent | 2aeeb55949c725aa2c28f11902afcd4eaefbb34a (diff) | |
download | cpython-219ffde846304915e173bd99833e30d012a58b82.zip cpython-219ffde846304915e173bd99833e30d012a58b82.tar.gz cpython-219ffde846304915e173bd99833e30d012a58b82.tar.bz2 |
Add Debug and Help menu items.
Diffstat (limited to 'Tools')
-rw-r--r-- | Tools/idle/Bindings.py | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/Tools/idle/Bindings.py b/Tools/idle/Bindings.py index 4f1ddac..4f833c6 100644 --- a/Tools/idle/Bindings.py +++ b/Tools/idle/Bindings.py @@ -100,6 +100,17 @@ emacs_bindings = [ "<<comment-region>>", "<Meta-Key-3>", "<Alt-Key-3>"), ("edit", "Uncomment region", "Alt-4", "<<uncomment-region>>", "<Meta-Key-4>", "<Alt-Key-4>"), + + # Debug menu + + ("debug", "Go to line from traceback", None, "<<goto-traceback-line>>"), + ("debug", "Open stack viewer", None, "<<open-stack-viewer>>"), + + # Help menu + + ("help", "Help...", None, "<<help>>"), + ("help", None, None), + ("help", "About IDLE...", None, "<<about-idle>>"), # Not in any menu @@ -134,11 +145,12 @@ def apply_bindings(text, bindings=default_bindings): def fill_menus(text, dict, bindings=default_bindings): # Fill the menus for the given text widget. The dict argument is # a dictionary containing the menus, keyed by their lowercased name. + # Menus that are absent or None are ignored. for args in bindings: menu, label, accelerator = args[:3] if not menu: continue - menu = dict[menu] + menu = dict.get(menu) if not menu: continue if accelerator is None: |