]> git.eshelyaron.com Git - emacs.git/commitdiff
(texinfo-show-structure): Bind inhibit-read-only.
authorKarl Heuer <kwzh@gnu.org>
Fri, 25 Sep 1998 17:01:52 +0000 (17:01 +0000)
committerKarl Heuer <kwzh@gnu.org>
Fri, 25 Sep 1998 17:01:52 +0000 (17:01 +0000)
lisp/textmodes/texinfo.el

index fb130817e5ab50941cd62a2c6be8f5cbb068aae4..cfd54d5cd09e64b1495530218fc1d1cf534dfaa3 100644 (file)
@@ -729,46 +729,47 @@ to jump to the corresponding spot in the Texinfo source file."
       (occur texinfo-section-types-regexp)))
   (pop-to-buffer "*Occur*")
   (goto-char (point-min))
-  (flush-lines "-----")
-  ;; Now format the "*Occur*" buffer to show the structure.
-  ;; Thanks to ceder@signum.se (Per Cederqvist)
-  (goto-char (point-max))
-  (let ((margin 5))
-    (while (re-search-backward "^ *[0-9]*:" nil 0)
-      (re-search-forward ":")
-      (setq margin
-            (cond
-             ((looking-at
-               (concat "@\\(" texinfo-chapter-level-regexp "\\)")) 5)
-             ;; ((looking-at "@chapter ") 5)
-             ;; ((looking-at "@unnumbered ") 5)
-             ;; ((looking-at "@appendix ") 5)
-             ;; ((looking-at "@majorheading ") 5)
-             ;; ((looking-at "@chapheading ") 5)
-
-             ((looking-at
-               (concat "@\\(" texinfo-section-level-regexp "\\)")) 9)
-             ;; ((looking-at "@section ") 9)
-             ;; ((looking-at "@unnumberedsec ") 9)
-             ;; ((looking-at "@appendixsec ") 9)
-             ;; ((looking-at "@heading ") 9)
-
-             ((looking-at
-               (concat "@\\(" texinfo-subsection-level-regexp "\\)")) 13)
-             ;; ((looking-at "@subsection ") 13)
-             ;; ((looking-at "@unnumberedsubsec ") 13)
-             ;; ((looking-at "@appendixsubsec ") 13)
-             ;; ((looking-at "@subheading ") 13)
-
-             ((looking-at
-               (concat "@\\(" texinfo-subsubsection-level-regexp "\\)")) 17)
-             ;; ((looking-at "@subsubsection ") 17)
-             ;; ((looking-at "@unnumberedsubsubsec ") 17)
-             ;; ((looking-at "@appendixsubsubsec ") 17)
-             ;; ((looking-at "@subsubheading ") 17)
-             (t margin)))
-      (indent-to-column margin)
-      (beginning-of-line))))
+  (let ((inhibit-read-only t))
+    (flush-lines "-----")
+    ;; Now format the "*Occur*" buffer to show the structure.
+    ;; Thanks to ceder@signum.se (Per Cederqvist)
+    (goto-char (point-max))
+    (let ((margin 5))
+      (while (re-search-backward "^ *[0-9]*:" nil 0)
+       (re-search-forward ":")
+       (setq margin
+             (cond
+              ((looking-at
+                (concat "@\\(" texinfo-chapter-level-regexp "\\)")) 5)
+              ;; ((looking-at "@chapter ") 5)
+              ;; ((looking-at "@unnumbered ") 5)
+              ;; ((looking-at "@appendix ") 5)
+              ;; ((looking-at "@majorheading ") 5)
+              ;; ((looking-at "@chapheading ") 5)
+
+              ((looking-at
+                (concat "@\\(" texinfo-section-level-regexp "\\)")) 9)
+              ;; ((looking-at "@section ") 9)
+              ;; ((looking-at "@unnumberedsec ") 9)
+              ;; ((looking-at "@appendixsec ") 9)
+              ;; ((looking-at "@heading ") 9)
+
+              ((looking-at
+                (concat "@\\(" texinfo-subsection-level-regexp "\\)")) 13)
+              ;; ((looking-at "@subsection ") 13)
+              ;; ((looking-at "@unnumberedsubsec ") 13)
+              ;; ((looking-at "@appendixsubsec ") 13)
+              ;; ((looking-at "@subheading ") 13)
+
+              ((looking-at
+                (concat "@\\(" texinfo-subsubsection-level-regexp "\\)")) 17)
+              ;; ((looking-at "@subsubsection ") 17)
+              ;; ((looking-at "@unnumberedsubsubsec ") 17)
+              ;; ((looking-at "@appendixsubsubsec ") 17)
+              ;; ((looking-at "@subsubheading ") 17)
+              (t margin)))
+       (indent-to-column margin)
+       (beginning-of-line)))))
 \f
 ;;; The  tex  and  print  function definitions: