]> code.delx.au - gnu-emacs/blobdiff - lisp/textmodes/texnfo-upd.el
(tmm-menubar-mouse): Add autoload cookie.
[gnu-emacs] / lisp / textmodes / texnfo-upd.el
index d43d1c50466df799c60831a5252ba7366a37b88f..cfd64adce4b1d7355584331b558e7991945923c4 100644 (file)
@@ -1,5 +1,6 @@
-;;; Texinfo mode utilities for updating nodes and menus in Texinfo files.
-;;; Copyright 1989, 1990, 1991, 1992 Free Software Foundation
+;;; texnfo-upd.el --- utilities for updating nodes and menus in Texinfo files
+
+;; Copyright (C) 1989, 1990, 1991, 1992 Free Software Foundation, Inc.
 
 ;; Author: Robert J. Chassell      
 ;; Maintainer: bug-texinfo@prep.ai.mit.edu
@@ -748,7 +749,7 @@ menus in the buffer (incorporating descriptions from pre-existing
 menus) before it constructs the master menu.
 
 The function removes the detailed part of an already existing master
-menu.  This action depends on the pre-exisitng master menu using the
+menu.  This action depends on the pre-existing master menu using the
 standard `texinfo-master-menu-header'.
 
 The master menu has the following format, which is adapted from the
@@ -1001,10 +1002,11 @@ error if the node is not the top node and a section is not found."
                            t)
         "top")
        ((re-search-forward texinfo-section-types-regexp nil t)
-        (buffer-substring (progn (beginning-of-line) ; copy its name
-                                 (1+ (point)))
-                          (progn (forward-word 1)
-                                 (point))))
+        (buffer-substring-no-properties
+        (progn (beginning-of-line) ; copy its name
+               (1+ (point)))
+        (progn (forward-word 1)
+               (point))))
        (t
         (error
          "texinfo-specific-section-type: Chapter or section not found."))))))
@@ -1347,10 +1349,9 @@ Point must be at beginning of node line.  Does not move point."
 Starts from the current position of the cursor, and searches forward
 on the line for a comma and if one is found, deletes the rest of the
 line, including the comma.  Leaves point at beginning of line."
-  (if (search-forward "," (save-excursion (end-of-line) (point)) t)
-      (progn
-        (goto-char (1- (point)))
-        (kill-line nil)))
+  (let ((eol-point (save-excursion (end-of-line) (point))))
+    (if (search-forward "," eol-point t)
+        (delete-region (1- (point)) eol-point)))
   (beginning-of-line))
 
 (defun texinfo-find-pointer (beginning end level direction)