emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/textmodes/makeinfo.el


From: Juanma Barranquero
Subject: [Emacs-diffs] Changes to emacs/lisp/textmodes/makeinfo.el
Date: Tue, 04 Feb 2003 08:30:46 -0500

Index: emacs/lisp/textmodes/makeinfo.el
diff -c emacs/lisp/textmodes/makeinfo.el:1.14 
emacs/lisp/textmodes/makeinfo.el:1.15
*** emacs/lisp/textmodes/makeinfo.el:1.14       Sun Dec 22 17:05:16 2002
--- emacs/lisp/textmodes/makeinfo.el    Tue Feb  4 08:30:44 2003
***************
*** 2,8 ****
  
  ;; Copyright (C) 1991, 1993, 2002 Free Software Foundation, Inc.
  
! ;; Author: Robert J. Chassell      
  ;; Maintainer: FSF
  ;; Keywords: docs convenience
  
--- 2,8 ----
  
  ;; Copyright (C) 1991, 1993, 2002 Free Software Foundation, Inc.
  
! ;; Author: Robert J. Chassell
  ;; Maintainer: FSF
  ;; Keywords: docs convenience
  
***************
*** 61,67 ****
    :group 'makeinfo)
  
  (defcustom makeinfo-options "--fill-column=70"
!   "*String containing options for running `makeinfo'.  
  Do not include `--footnote-style' or `--paragraph-indent';
  the proper way to specify those is with the Texinfo commands
  address@hidden and address@hidden'."
--- 61,67 ----
    :group 'makeinfo)
  
  (defcustom makeinfo-options "--fill-column=70"
!   "*String containing options for running `makeinfo'.
  Do not include `--footnote-style' or `--paragraph-indent';
  the proper way to specify those is with the Texinfo commands
  address@hidden and address@hidden'."
***************
*** 91,97 ****
  This command does not offer the `next-error' feature since it would
  apply to a temporary file, not the original; use the `makeinfo-buffer'
  command to gain use of `next-error'."
!   
    (interactive "r")
    (let (filename-or-header
          filename-or-header-beginning
--- 91,97 ----
  This command does not offer the `next-error' feature since it would
  apply to a temporary file, not the original; use the `makeinfo-buffer'
  command to gain use of `next-error'."
! 
    (interactive "r")
    (let (filename-or-header
          filename-or-header-beginning
***************
*** 104,114 ****
            (concat
             (make-temp-file
              (substring (buffer-file-name)
!                        0 
!                        (or (string-match "\\.tex" (buffer-file-name)) 
                             (length (buffer-file-name)))))
             ".texinfo"))
!     
      (save-excursion
        (save-restriction
          (widen)
--- 104,114 ----
            (concat
             (make-temp-file
              (substring (buffer-file-name)
!                        0
!                        (or (string-match "\\.tex" (buffer-file-name))
                             (length (buffer-file-name)))))
             ".texinfo"))
! 
      (save-excursion
        (save-restriction
          (widen)
***************
*** 116,149 ****
          (let ((search-end (save-excursion (forward-line 100) (point))))
            ;; Find and record the Info filename,
            ;; or else explain that a filename is needed.
!           (if (re-search-forward 
                 "address@hidden \t]+\\([^ \t\n]+\\)[ \t]*"
                 search-end t)
!               (setq makeinfo-output-file-name 
                      (buffer-substring (match-beginning 1) (match-end 1)))
              (error
               "The texinfo file needs a line saying: @setfilename <name>"))
  
            ;; Find header and specify its beginning and end.
            (goto-char (point-min))
!           (if (and 
!                (prog1 
                     (search-forward tex-start-of-header search-end t)
                   (beginning-of-line)
                   ;; Mark beginning of header.
                   (setq filename-or-header-beginning (point)))
!                (prog1 
                     (search-forward tex-end-of-header nil t)
                   (beginning-of-line)
                   ;; Mark end of header
                   (setq filename-or-header-end (point))))
!               
                ;; Insert the header into the temporary file.
                (write-region
                 (min filename-or-header-beginning region-beginning)
                 filename-or-header-end
                 makeinfo-temp-file nil nil)
!             
              ;; Else no header; insert @filename line into temporary file.
              (goto-char (point-min))
              (search-forward "@setfilename" search-end t)
--- 116,149 ----
          (let ((search-end (save-excursion (forward-line 100) (point))))
            ;; Find and record the Info filename,
            ;; or else explain that a filename is needed.
!           (if (re-search-forward
                 "address@hidden \t]+\\([^ \t\n]+\\)[ \t]*"
                 search-end t)
!               (setq makeinfo-output-file-name
                      (buffer-substring (match-beginning 1) (match-end 1)))
              (error
               "The texinfo file needs a line saying: @setfilename <name>"))
  
            ;; Find header and specify its beginning and end.
            (goto-char (point-min))
!           (if (and
!                (prog1
                     (search-forward tex-start-of-header search-end t)
                   (beginning-of-line)
                   ;; Mark beginning of header.
                   (setq filename-or-header-beginning (point)))
!                (prog1
                     (search-forward tex-end-of-header nil t)
                   (beginning-of-line)
                   ;; Mark end of header
                   (setq filename-or-header-end (point))))
! 
                ;; Insert the header into the temporary file.
                (write-region
                 (min filename-or-header-beginning region-beginning)
                 filename-or-header-end
                 makeinfo-temp-file nil nil)
! 
              ;; Else no header; insert @filename line into temporary file.
              (goto-char (point-min))
              (search-forward "@setfilename" search-end t)
***************
*** 155,161 ****
               (min filename-or-header-beginning region-beginning)
               filename-or-header-end
               makeinfo-temp-file nil nil))
!           
            ;; Insert the region into the file.
            (write-region
             (max region-beginning filename-or-header-end)
--- 155,161 ----
               (min filename-or-header-beginning region-beginning)
               filename-or-header-end
               makeinfo-temp-file nil nil))
! 
            ;; Insert the region into the file.
            (write-region
             (max region-beginning filename-or-header-end)
***************
*** 168,174 ****
               (concat makeinfo-run-command
                       " "
                       makeinfo-options
!                      " " 
                       makeinfo-temp-file)
               "Use `makeinfo-buffer' to gain use of the `next-error' command"
             nil
--- 168,174 ----
               (concat makeinfo-run-command
                       " "
                       makeinfo-options
!                      " "
                       makeinfo-temp-file)
               "Use `makeinfo-buffer' to gain use of the `next-error' command"
             nil
***************
*** 220,250 ****
  (defun makeinfo-buffer ()
    "Make Info file from current buffer.
  
! Use the \\[next-error] command to move to the next error 
  \(if there are errors\)."
!  
    (interactive)
    (cond ((null buffer-file-name)
           (error "Buffer not visiting any file"))
          ((buffer-modified-p)
           (if (y-or-n-p "Buffer modified; do you want to save it? ")
               (save-buffer))))
!   
    ;; Find and record the Info filename,
    ;; or else explain that a filename is needed.
    (save-excursion
      (goto-char (point-min))
      (let ((search-end (save-excursion (forward-line 100) (point))))
!       (if (re-search-forward 
             "address@hidden \t]+\\([^ \t\n]+\\)[ \t]*"
             search-end t)
!           (setq makeinfo-output-file-name 
                  (expand-file-name
                   (buffer-substring (match-beginning 1) (match-end 1))))
          (error
           "The texinfo file needs a line saying: @setfilename <name>"))))
    (setq makeinfo-output-node-name (makeinfo-current-node))
!   
    (save-excursion
      (makeinfo-compile
       (concat makeinfo-run-command " " makeinfo-options
--- 220,250 ----
  (defun makeinfo-buffer ()
    "Make Info file from current buffer.
  
! Use the \\[next-error] command to move to the next error
  \(if there are errors\)."
! 
    (interactive)
    (cond ((null buffer-file-name)
           (error "Buffer not visiting any file"))
          ((buffer-modified-p)
           (if (y-or-n-p "Buffer modified; do you want to save it? ")
               (save-buffer))))
! 
    ;; Find and record the Info filename,
    ;; or else explain that a filename is needed.
    (save-excursion
      (goto-char (point-min))
      (let ((search-end (save-excursion (forward-line 100) (point))))
!       (if (re-search-forward
             "address@hidden \t]+\\([^ \t\n]+\\)[ \t]*"
             search-end t)
!           (setq makeinfo-output-file-name
                  (expand-file-name
                   (buffer-substring (match-beginning 1) (match-end 1))))
          (error
           "The texinfo file needs a line saying: @setfilename <name>"))))
    (setq makeinfo-output-node-name (makeinfo-current-node))
! 
    (save-excursion
      (makeinfo-compile
       (concat makeinfo-run-command " " makeinfo-options




reply via email to

[Prev in Thread] Current Thread [Next in Thread]