diff options
author | Alan Mackenzie <acm@muc.de> | 2017-06-15 20:47:11 +0000 |
---|---|---|
committer | Alan Mackenzie <acm@muc.de> | 2017-06-15 21:03:03 +0000 |
commit | 7a2038d7c887e4fa08a91950a7494d1dd20c39e1 (patch) | |
tree | 3aca6adb27e83c129c9a2f2cebffef55e679fcde /lisp/emacs-lisp/cl-indent.el | |
parent | 21d10e59f89a5bb72829ffb8ebe4463ba4fac124 (diff) | |
download | emacs-7a2038d7c887e4fa08a91950a7494d1dd20c39e1.tar.gz emacs-7a2038d7c887e4fa08a91950a7494d1dd20c39e1.tar.bz2 emacs-7a2038d7c887e4fa08a91950a7494d1dd20c39e1.zip |
Create a toggle between block and line comments in CC Mode.
Also (unrelated change) initialize the modes' keymaps at each loading.
* lisp/progmodes/cc-cmds.el (c-update-modeline): amend for the new information
on the modeline.
(c-block-comment-flag): New variable.
(c-toggle-comment-style): New function.
* lisp/progmodes/cc-langs.el (c-block-comment-starter)
(c-line-comment-starter): Make them c-lang-defvars.
(c-block-comment-is-default): New c-lang-defvar.
(comment-start, comment-end): Make the default values dependent on
c-block-comment-is-default.
* lisp/progmodes/cc-mode.el (c-mode-base-map): Define C-c C-k in this map.
(c-basic-common-init): Initialize c-block-comment-flag.
(c-mode-map, c++-mode-map, objc-mode-map, java-mode-map, idl-mode-map)
(pike-mode-map, awk-mode-map): Make entries in these key maps each time the
mode is loaded rather than just once per Emacs session.
* doc/misc/cc-mode.texi (Comment Commands): Introduce the notion of comment
style.
(Minor Modes): Define comment style. Describe how comment style influences
the information displayed on the modeline. Document c-toggle-comment-style.
(FAQ): Add a question about toggling the comment style.
Diffstat (limited to 'lisp/emacs-lisp/cl-indent.el')
0 files changed, 0 insertions, 0 deletions