aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard M. Stallman1993-11-20 22:21:58 +0000
committerRichard M. Stallman1993-11-20 22:21:58 +0000
commit79183f1a1f340bcffa95f1e2dad06883d65b0ed7 (patch)
treea84aad2addb154eb56e80e785f14e4560044a8bd
parent30803a05ce0c34bc09196b748e4d50bce73df7eb (diff)
downloademacs-79183f1a1f340bcffa95f1e2dad06883d65b0ed7.tar.gz
emacs-79183f1a1f340bcffa95f1e2dad06883d65b0ed7.zip
(texinfo-tex-region): Use tex-send-command to do commands.
(texinfo-tex-buffer, texinfo-texindex, texinfo-tex-print): Likewise. (texinfo-delete-from-print-queue, texinfo-quit-job): Likewise.
-rw-r--r--lisp/textmodes/texinfo.el33
1 files changed, 8 insertions, 25 deletions
diff --git a/lisp/textmodes/texinfo.el b/lisp/textmodes/texinfo.el
index 1ea2832845b..a3cc2defdf3 100644
--- a/lisp/textmodes/texinfo.el
+++ b/lisp/textmodes/texinfo.el
@@ -673,10 +673,8 @@ The value of `texinfo-tex-trailer' is appended to the temporary file after the r
673 )) 673 ))
674 674
675 (tex-set-buffer-directory "*tex-shell*" zap-directory) 675 (tex-set-buffer-directory "*tex-shell*" zap-directory)
676 (send-string "tex-shell" (concat tex-shell-cd-command " " 676 (tex-send-command tex-shell-cd-command zap-directory)
677 zap-directory "\n")) 677 (tex-send-command texinfo-tex-command tex-out-file))
678 (send-string "tex-shell" (concat texinfo-tex-command " "
679 tex-out-file "\n")))
680 (tex-recenter-output-buffer 0)) 678 (tex-recenter-output-buffer 0))
681 679
682(defun texinfo-tex-buffer () 680(defun texinfo-tex-buffer ()
@@ -696,12 +694,9 @@ The value of `texinfo-tex-trailer' is appended to the temporary file after the r
696 694
697 (setq tex-zap-file buffer-file-name) 695 (setq tex-zap-file buffer-file-name)
698 696
699 (send-string "tex-shell" 697 (tex-send-command tex-shell-cd-command (file-name-directory tex-zap-file))
700 (concat tex-shell-cd-command
701 " " (file-name-directory tex-zap-file) "\n"))
702 698
703 (send-string "tex-shell" 699 (tex-send-command texinfo-texi2dvi-command tex-zap-file)
704 (concat texinfo-texi2dvi-command " " tex-zap-file "\n"))
705 700
706 (tex-recenter-output-buffer 0)) 701 (tex-recenter-output-buffer 0))
707 702
@@ -711,9 +706,7 @@ The index files are made by \\[texinfo-tex-region] or \\[texinfo-tex-buffer].
711This runs the shell command defined by `texinfo-texindex-command'." 706This runs the shell command defined by `texinfo-texindex-command'."
712 (interactive) 707 (interactive)
713 (require 'tex-mode) 708 (require 'tex-mode)
714 (send-string "tex-shell" 709 (tex-send-command texinfo-texindex-command (concat tex-zap-file ".??"))
715 (concat texinfo-texindex-command
716 " " tex-zap-file ".??" "\n"))
717 (tex-recenter-output-buffer nil)) 710 (tex-recenter-output-buffer nil))
718 711
719(defun texinfo-tex-print () 712(defun texinfo-tex-print ()
@@ -721,9 +714,7 @@ This runs the shell command defined by `texinfo-texindex-command'."
721This runs the shell command defined by `tex-dvi-print-command'." 714This runs the shell command defined by `tex-dvi-print-command'."
722 (interactive) 715 (interactive)
723 (require 'tex-mode) 716 (require 'tex-mode)
724 (send-string "tex-shell" 717 (tex-send-command tex-dvi-print-command (concat tex-zap-file ".dvi"))
725 (concat tex-dvi-print-command
726 " " tex-zap-file ".dvi" "\n"))
727 (tex-recenter-output-buffer nil)) 718 (tex-recenter-output-buffer nil))
728 719
729(defun texinfo-quit-job () 720(defun texinfo-quit-job ()
@@ -731,11 +722,7 @@ This runs the shell command defined by `tex-dvi-print-command'."
731 (interactive) 722 (interactive)
732 (if (not (get-process "tex-shell")) 723 (if (not (get-process "tex-shell"))
733 (error "No TeX shell running")) 724 (error "No TeX shell running"))
734 (save-excursion 725 (tex-send-command "x"))
735 (set-buffer (get-buffer "*tex-shell*"))
736 (goto-char (point-max))
737 (insert "x")
738 (comint-send-input)))
739 726
740(defun texinfo-delete-from-print-queue (job-number) 727(defun texinfo-delete-from-print-queue (job-number)
741 "Delete job from the line printer spooling queue. 728 "Delete job from the line printer spooling queue.
@@ -746,11 +733,7 @@ You are prompted for the job number (use a number shown by a previous
746 (if (tex-shell-running) 733 (if (tex-shell-running)
747 (tex-kill-job) 734 (tex-kill-job)
748 (tex-start-shell)) 735 (tex-start-shell))
749 (send-string "tex-shell" 736 (tex-send-command texinfo-delete-from-print-queue-command job-number)
750 (concat
751 texinfo-delete-from-print-queue-command
752 " "
753 job-number"\n"))
754 (tex-recenter-output-buffer nil)) 737 (tex-recenter-output-buffer nil))
755 738
756(provide 'texinfo) 739(provide 'texinfo)