comparison yatexlib.el @ 524:b1896ef49747 dev

Detection of region passed to filter modified.
author HIROSE Yuuji <yuuji@gentei.org>
date Tue, 23 Jan 2018 10:44:10 +0900
parents b6853d450b0a
children b742adfa30e2
comparison
equal deleted inserted replaced
523:5bb46b7ab3de 524:b1896ef49747
1 ;;; yatexlib.el --- YaTeX and yahtml common libraries -*- coding: sjis -*- 1 ;;; yatexlib.el --- YaTeX and yahtml common libraries -*- coding: sjis -*-
2 ;;; 2 ;;;
3 ;;; (c)1994-2018 by HIROSE Yuuji.[yuuji@yatex.org] 3 ;;; (c)1994-2018 by HIROSE Yuuji.[yuuji@yatex.org]
4 ;;; Last modified Thu Jan 4 13:58:20 2018 on firestorm 4 ;;; Last modified Sun Jan 21 16:29:01 2018 on firestorm
5 ;;; $Id$ 5 ;;; $Id$
6 6
7 ;;; Code: 7 ;;; Code:
8 8
9 ;; High-precedence compatible function 9 ;; High-precedence compatible function
1222 (goto-char (match-end 0)) 1222 (goto-char (match-end 0))
1223 ;;(end-of-line) ;OUT 2015/1/5 1223 ;;(end-of-line) ;OUT 2015/1/5
1224 ;;(if (eobp) nil (forward-char 1)) ;OUT 2015/1/5 1224 ;;(if (eobp) nil (forward-char 1)) ;OUT 2015/1/5
1225 )))) 1225 ))))
1226 1226
1227 (defun YaTeX-in-BEGEND-p () 1227 (defun YaTeX-in-BEGEND-p (&optional pt)
1228 "Check if the point is in a %#BEGIN...%#END region. 1228 "Check if the point (or PT) is in a %#BEGIN...%#END region.
1229 Return the list of beginning and ending point of the region and arg-string 1229 Return the list of beginning and ending point of the region and arg-string
1230 if the point is in BEGEND. Otherwise nil." 1230 if the point is in BEGEND. Otherwise nil."
1231 (let ((b "%#BEGIN") bp args (e "%#END") (p (point))) 1231 (let ((b "%#BEGIN") bp args (e "%#END") (p (point)))
1232 (save-excursion 1232 (save-excursion
1233 (save-match-data ;emacs-19+ yatex1.80+ 1233 (save-match-data ;emacs-19+ yatex1.80+

yatex.org