From: Dave Love Date: Sat, 6 Mar 1999 19:07:47 +0000 (+0000) Subject: (c-outline-level): Bind X-Git-Tag: emacs-20.4~502 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=f87880f53d91252e469159b43bfa5b98417b8f7a;p=emacs.git (c-outline-level): Bind buffer-invisibility-spec. --- diff --git a/lisp/progmodes/c-mode.el b/lisp/progmodes/c-mode.el index ab9cf8dc992..1d3c241c96f 100644 --- a/lisp/progmodes/c-mode.el +++ b/lisp/progmodes/c-mode.el @@ -390,9 +390,11 @@ if that value is non-nil." (run-hooks 'c-mode-hook)) (defun c-outline-level () - (save-excursion - (skip-chars-forward "\t ") - (current-column))) + ;; This so that `current-column' DTRT in otherwise-hidden text. + (let (buffer-invisibility-spec) + (save-excursion + (skip-chars-forward "\t ") + (current-column)))) ;; This is used by indent-for-comment ;; to decide how much to indent a comment in C code diff --git a/lisp/progmodes/cc-cmds.el b/lisp/progmodes/cc-cmds.el index dfe34be8e66..35f1d0917c7 100644 --- a/lisp/progmodes/cc-cmds.el +++ b/lisp/progmodes/cc-cmds.el @@ -1065,9 +1065,11 @@ comment." ;; used by outline-minor-mode (defun c-outline-level () - (save-excursion - (skip-chars-forward "\t ") - (current-column))) + ;; This so that `current-column' DTRT in otherwise-hidden text. + (let (buffer-invisibility-spec) + (save-excursion + (skip-chars-forward "\t ") + (current-column)))) (defun c-up-conditional (count)