yatex
diff yatex.el @ 227:3b2ac4652810
Handling of built-in is changed to use YaTeX-getset-builtin.
author | yuuji@gentei.org |
---|---|
date | Mon, 23 Jan 2012 01:19:36 +0900 |
parents | 9705855793ca |
children | ccc75ecb360f |
line diff
1.1 --- a/yatex.el Sun Jan 22 21:37:09 2012 +0900 1.2 +++ b/yatex.el Mon Jan 23 01:19:36 2012 +0900 1.3 @@ -2,7 +2,7 @@ 1.4 ;;; Yet Another tex-mode for emacs - //–ì’¹// 1.5 ;;; yatex.el rev. 1.75.1 1.6 ;;; (c)1991-2012 by HIROSE Yuuji.[yuuji@yatex.org] 1.7 -;;; Last modified Sun Jan 22 15:48:09 2012 on firestorm 1.8 +;;; Last modified Mon Jan 23 01:11:49 2012 on firestorm 1.9 ;;; $Id$ 1.10 ;;; The latest version of this software is always available at; 1.11 ;;; http://www.yatex.org/ 1.12 @@ -1618,9 +1618,9 @@ 1.13 ((= c ?r) (YaTeX-typeset-region)) 1.14 ((= c ?e) (YaTeX-typeset-environment)) 1.15 ((= c ?b) (YaTeX-call-builtin-on-file 1.16 - "BIBTEX" bibtex-command)) 1.17 + "BIBTEX" bibtex-command arg)) 1.18 ((= c ?i) (YaTeX-call-builtin-on-file 1.19 - "MAKEINDEX" makeindex-command)) 1.20 + "MAKEINDEX" makeindex-command arg)) 1.21 ((= c ?k) (YaTeX-kill-typeset-process YaTeX-typeset-process)) 1.22 ((= c ?p) (call-interactively 'YaTeX-preview)) 1.23 ((= c ?q) (YaTeX-system "lpq" "*Printer queue*")) 1.24 @@ -1639,26 +1639,18 @@ 1.25 "Operate %# notation." 1.26 ;;Do not use interactive"r" for the functions which require no mark 1.27 (interactive) 1.28 - (message "!)Edit-%%#! B)EGIN-END-region L)Edit-%%#LPR") 1.29 + (message "!)Edit-%%#! B)EGIN-END-region P)review L)Edit-%%#LPR M)akeindex B)ibtex") 1.30 (let ((c (or char (read-char))) (string "") key 1.31 (b (make-marker)) (e (make-marker))) 1.32 (save-excursion 1.33 (cond 1.34 - ((or (= c ?!) (= c ?l)) ;Edit `%#!' 1.35 - (goto-char (point-min)) 1.36 - (setq key (cond ((= c ?!) "%#!") 1.37 - ((= c ?l) "%#LPR"))) 1.38 - (if (re-search-forward key nil t) 1.39 - (progn 1.40 - (setq string (YaTeX-buffer-substring 1.41 - (point) (point-end-of-line))) 1.42 - (delete-region (point) (progn (end-of-line) (point)))) 1.43 - (open-line 1) 1.44 - (delete-region (point) (progn (beginning-of-line)(point)));for 19 :-< 1.45 - (insert key)) 1.46 - (unwind-protect 1.47 - (setq string (read-string (concat key ": ") string)) 1.48 - (insert string))) 1.49 + ((rindex "!plmb" c) ;Edit %#xxx 1.50 + (setq key (cdr (assq c '((?! . "!") 1.51 + (?p . "PREVIEW") 1.52 + (?l . "LPR") 1.53 + (?m . "MAKEINDEX") 1.54 + (?b . "BIBTEX"))))) 1.55 + (YaTeX-getset-builtin key t)) 1.56 1.57 ((= c ?b) ;%#BEGIN %#END region 1.58 (or end (setq beg (min (point) (mark)) end (max (point) (mark))))