yatex
changeset 408:2857cac50a67 dev
When PDF output seems to occur in typesetter, use pdf-viewer in [prefix] t p.
author | HIROSE Yuuji <yuuji@gentei.org> |
---|---|
date | Mon, 19 Jan 2015 09:00:07 +0900 |
parents | b423cf9b35ee |
children | 781604df4cbd |
files | yatex.new yatexprc.el |
diffstat | 2 files changed, 12 insertions(+), 2 deletions(-) [+] |
line diff
1.1 --- a/yatex.new Sun Jan 18 23:42:31 2015 +0900 1.2 +++ b/yatex.new Mon Jan 19 09:00:07 2015 +0900 1.3 @@ -9,6 +9,7 @@ 1.4 持続中の On-the-fly preview の無効化は何もない場所で [prefix] k。 1.5 YaTeX-help-file のデフォルト位置を site-lisp/yatex/help/ に変更。 1.6 領域活性時に呼び出す補完は領域括りになるようにした。 1.7 + タイプセットでPDF出力がありそうなときは次回previewをPDFヴューアに。 1.8 === yahtml === 1.9 領域活性時に呼び出す補完は領域括りになるようにした。 1.10 ...
2.1 --- a/yatexprc.el Sun Jan 18 23:42:31 2015 +0900 2.2 +++ b/yatexprc.el Mon Jan 19 09:00:07 2015 +0900 2.3 @@ -1,7 +1,7 @@ 2.4 ;;; yatexprc.el --- YaTeX process handler -*- coding: sjis -*- 2.5 ;;; 2.6 ;;; (c)1993-2015 by HIROSE Yuuji.[yuuji@yatex.org] 2.7 -;;; Last modified Sun Jan 18 23:17:57 2015 on firestorm 2.8 +;;; Last modified Mon Jan 19 08:35:39 2015 on firestorm 2.9 ;;; $Id$ 2.10 2.11 ;;; Code: 2.12 @@ -299,7 +299,16 @@ 2.13 'YaTeX-typeset-sentinel)) 2.14 (t 2.15 (if (equal 0 (process-exit-status proc)) 2.16 - nil ;do nothing at successful exit 2.17 + ;; Successful typesetting done 2.18 + (if (save-excursion 2.19 + (re-search-backward 2.20 + (concat 2.21 + "^Output written on .*\\.pdf (.*page," 2.22 + "\\|\\.dvi -> .*\\.pdf$") 2.23 + nil t)) 2.24 + ;; If PDF output log found in buffer, 2.25 + ;; set next default previewer to 'pdf viewer 2.26 + (put 'dvi2-command 'format 'pdf)) 2.27 ;;Confirm process buffer to be shown when error 2.28 (YaTeX-showup-buffer 2.29 pbuf 'YaTeX-showup-buffer-bottom-most)