aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorStefan Monnier2000-11-14 10:04:20 +0000
committerStefan Monnier2000-11-14 10:04:20 +0000
commitd3fcda2278c4546002d00524d02570e7c2b27128 (patch)
treeda5b86b61b90b73dfe61938d7d85d0b7289a3a2d
parent1594a23a930fda645452eb02d480bb61091cdf65 (diff)
downloademacs-d3fcda2278c4546002d00524d02570e7c2b27128.tar.gz
emacs-d3fcda2278c4546002d00524d02570e7c2b27128.zip
(comment-indent-default): Stick \s<\s< to the left
when it follows non-comment text on the line.
-rw-r--r--lisp/ChangeLog11
-rw-r--r--lisp/newcomment.el6
2 files changed, 15 insertions, 2 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 04ff21d2e7d..296133f9afb 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,14 @@
12000-11-14 Stefan Monnier <monnier@cs.yale.edu>
2
3 * newcomment.el (comment-indent-default): Stick \s<\s< to the left
4 when it follows non-comment text on the line.
5
6 * emacs-lisp/lisp-mode.el (lisp-mode-variables):
7 Set font-lock-defaults.
8 (lisp-mode-shared-map): Init inside the defvar.
9 (emacs-lisp-mode, lisp-mode, lisp-interaction-mode):
10 Use define-derived-mode.
11
12000-11-14 Miles Bader <miles@lsi.nec.co.jp> 122000-11-14 Miles Bader <miles@lsi.nec.co.jp>
2 13
3 * faces.el (header-line): Use `:box nil' for color/gs displays too. 14 * faces.el (header-line): Use `:box nil' for color/gs displays too.
diff --git a/lisp/newcomment.el b/lisp/newcomment.el
index b4bdc16ba2c..4675370fdf7 100644
--- a/lisp/newcomment.el
+++ b/lisp/newcomment.el
@@ -6,7 +6,7 @@
6;; Maintainer: Stefan Monnier <monnier@cs.yale.edu> 6;; Maintainer: Stefan Monnier <monnier@cs.yale.edu>
7;; Keywords: comment uncomment 7;; Keywords: comment uncomment
8;; Version: $Name: $ 8;; Version: $Name: $
9;; Revision: $Id: newcomment.el,v 1.21 2000/10/05 22:43:22 monnier Exp $ 9;; Revision: $Id: newcomment.el,v 1.22 2000/10/08 19:07:41 monnier Exp $
10 10
11;; This file is part of GNU Emacs. 11;; This file is part of GNU Emacs.
12 12
@@ -399,7 +399,9 @@ Point is assumed to be just at the end of a comment."
399;;;###autoload 399;;;###autoload
400(defun comment-indent-default () 400(defun comment-indent-default ()
401 "Default for `comment-indent-function'." 401 "Default for `comment-indent-function'."
402 (if (looking-at "\\s<\\s<\\s<") 0 402 (if (and (looking-at "\\s<\\s<\\(\\s<\\)?")
403 (or (match-end 1) (/= (current-column) (current-indentation))))
404 0
403 (when (or (/= (current-column) (current-indentation)) 405 (when (or (/= (current-column) (current-indentation))
404 (and (> comment-add 0) (looking-at "\\s<\\S<"))) 406 (and (> comment-add 0) (looking-at "\\s<\\S<")))
405 comment-column))) 407 comment-column)))