> Please, don't spawn a new thread just to provide a new revised patch,
   > just reply to my email.  I'd like to review other patches you lately
   > submitted, but I've to navigate between all the threads you opened to
   > discover which one has the latest version of a specific patch.

New patch using git.

>From 989e406171c00edd1264db2a7ed0a21d5e169b5c Mon Sep 17 00:00:00 2001
From: Uwe <o...@mat.ucm.es>
Date: Sat, 17 Sep 2016 16:27:10 +0000
Subject: [PATCH] Improve style/bidi and add make file entry.

* Makefile.in (STYLESRC): add bidi.el

* style/bidi.el ("bidi"):    Add (TeX-check-engine-add-engines 'xetex)
---
 Makefile.in   |  3 ++-
 style/bidi.el | 59 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 61 insertions(+), 1 deletion(-)
 create mode 100755 style/bidi.el

diff --git a/Makefile.in b/Makefile.in
index 014f5be..84e2bd5 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -156,7 +156,8 @@ STYLESRC = style/prosper.el \
 	   style/hologo.el    style/theorem.el   style/ntheorem.el \
 	   style/splitidx.el  style/tikz.el      style/xcolor.el \
 	   style/pdflscape.el style/commath.el   style/empheq.el \
-	   style/framed.el    style/paracol.el   style/menukeys.el
+	   style/framed.el    style/paracol.el   style/menukeys.el \
+	   style/bidi.el
 
 STYLEELC = $(STYLESRC:.el=.elc)
 
diff --git a/style/bidi.el b/style/bidi.el
new file mode 100755
index 0000000..df607f9
--- /dev/null
+++ b/style/bidi.el
@@ -0,0 +1,59 @@
+;;; bidi.el --- AUCTeX style for the (XeLaTeX) bidi package
+
+;; Copyright (C) Free Software Foundation
+
+;; Author: Uwe Brauer <o...@mat.ucm.es>
+;; Created: 2016-03-06
+;; Keywords: tex
+
+;; This file is part of AUCTeX.
+
+;; AUCTeX is free software; you can redistribute it and/or modify it
+;; under the terms of the GNU General Public License as published by
+;; the Free Software Foundation; either version 3, or (at your option)
+;; any later version.
+
+;; AUCTeX is distributed in the hope that it will be useful, but
+;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+;; General Public License for more details.
+
+;; You should have received a copy of the GNU General Public License
+;; along with AUCTeX; see the file COPYING.  If not, write to the Free
+;; Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+;; 02110-1301, USA.
+
+;;; Commentary:
+
+;; This file adds support for the bidi package.
+
+;;; Code:
+
+(defvar LaTeX-bidi-package-options '("RTLdocument" "rldocuement")
+  "Package options for the bidi package.")
+
+(TeX-add-style-hook
+ "bidi"
+ (lambda ()
+   (TeX-check-engine-add-engines 'xetex)
+   (LaTeX-add-environments
+    "LTR"
+    "RTL")
+   ;; Fontification
+   (TeX-add-symbols
+    '("setRL" 0)
+    '("unsetRL" 0)
+    '("setRTL" 0)
+    '("unsetRTL" 0)
+    '("setLR" 0)
+    '("unsetLR" 0)
+    '("setLTR" 0)
+    '("unsetLTR" 0)
+    '("LR" 1)
+    '("LRE" 1)
+    '("RLE" 1)
+    '("RL" 1)))
+ LaTeX-dialect)
+
+
+;;; bidi.el ends here
-- 
1.9.1

_______________________________________________
auctex-devel mailing list
auctex-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/auctex-devel

Reply via email to