Mercurial > cpython-lru_cache-weakref
diff Misc/python-mode.el @ 6669:2f5c8374825c legacy-trunk
(py-mark-def-or-class): Added an exchange-point-and-mark and a
py-keep-region-active so that the marked def/class gets the
zmacs-region or transient-mark region highlighted. Also point should
be left at the end of the marked region.
(py-mode-map): Moved py-mark-def-or-class to M-C-h to conform to Emacs
major mode standards.
| author | Barry Warsaw <barry@python.org> |
|---|---|
| date | Wed, 26 Nov 1997 06:00:26 +0000 |
| parents | 98552704b88f |
| children | 8e3ee3577d4e |
line wrap: on
line diff
--- a/Misc/python-mode.el Wed Nov 26 05:40:58 1997 +0000 +++ b/Misc/python-mode.el Wed Nov 26 06:00:26 1997 +0000 @@ -462,7 +462,7 @@ (define-key py-mode-map [delete] 'py-electric-delete) (define-key py-mode-map [backspace] 'py-electric-backspace)) ;; marking interesting locations - (define-key py-mode-map "\C-c\C-m" 'py-mark-def-or-class) + (define-key py-mode-map "\e\C-h" 'py-mark-def-or-class) (define-key py-mode-map "\C-c\C-k" 'py-mark-block) ;; Miscellaneous (define-key py-mode-map "\C-c:" 'py-guess-indent-offset) @@ -2049,7 +2049,9 @@ (re-search-backward "^[ \t]*[^ \t#]" nil 'move) (forward-line 1)) ;; no comment, so go back - (goto-char start)))))))) + (goto-char start))))))) + (exchange-point-and-mark) + (py-keep-region-active)) ;; ripped from cc-mode (defun py-forward-into-nomenclature (&optional arg)
