yatex

changeset 245:8ad85ce1ee98 dev

YaTeX-on-section-command-p tries to escape parentheses.
author yuuji@gentei.org
date Thu, 09 Feb 2012 09:54:06 +0900
parents d5e0c33d7dfd
children 9105918e45a2
files yatex.el
diffstat 1 files changed, 6 insertions(+), 1 deletions(-) [+]
line diff
     1.1 --- a/yatex.el	Thu Feb 09 08:45:22 2012 +0900
     1.2 +++ b/yatex.el	Thu Feb 09 09:54:06 2012 +0900
     1.3 @@ -2,7 +2,7 @@
     1.4  ;;; Yet Another tex-mode for emacs - //–ì’¹//
     1.5  ;;; yatex.el rev. 1.75.3
     1.6  ;;; (c)1991-2012 by HIROSE Yuuji.[yuuji@yatex.org]
     1.7 -;;; Last modified Sun Jan 29 19:35:24 2012 on firestorm
     1.8 +;;; Last modified Thu Feb  9 09:52:41 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 @@ -2003,6 +2003,11 @@
    1.13  		 (looking-at ec+command))
    1.14  	       (goto-char (match-beginning 0))
    1.15  	       (throw 'found t))
    1.16 +	  ;;If inside of parentheses, try to escape.
    1.17 +	  (while (condition-case err
    1.18 +		     (progn (up-list -1) t)
    1.19 +		   (error nil)))
    1.20 +	  (while (equal (preceding-char) ?\]) (backward-list))
    1.21  	  ;;(2) search command directly
    1.22  	  (skip-chars-forward "^{}[]")
    1.23  	  (and (YaTeX-re-search-active-backward