Function: TeX-dvips-sentinel
TeX-dvips-sentinel is a byte-compiled function defined in tex.el.
Signature
(TeX-dvips-sentinel PROCESS NAME)
Documentation
Cleanup TeX output buffer after running dvips.
Source Code
;; Defined in ~/.emacs.d/elpa/auctex-14.1.2/tex.el
(defun TeX-dvips-sentinel (_process _name)
"Cleanup TeX output buffer after running dvips."
(goto-char (point-max))
(cond
((search-backward "TeX Output exited abnormally" nil t)
(message "Dvips failed. Type `%s' to display output."
(substitute-command-keys
"\\<TeX-mode-map>\\[TeX-recenter-output-buffer]")))
(t
(if (with-current-buffer TeX-command-buffer
(and (equal (TeX-PDF-from-DVI) "Dvips") TeX-PDF-mode))
(setq TeX-output-extension "ps"
TeX-command-next "Ps2pdf"))
(message "Dvips finished successfully. "))))