auctex-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[AUCTeX-diffs] GNU AUCTeX branch, master, updated. 8a14439f4fbb0f8e5d30c


From: Mosè Giordano
Subject: [AUCTeX-diffs] GNU AUCTeX branch, master, updated. 8a14439f4fbb0f8e5d30c689b339e32effbe0177
Date: Wed, 23 Nov 2016 23:14:40 +0000 (UTC)

This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU AUCTeX".

The branch, master has been updated
       via  8a14439f4fbb0f8e5d30c689b339e32effbe0177 (commit)
      from  80d2a087963676fd98683ab04dfd685e5b91ff81 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 8a14439f4fbb0f8e5d30c689b339e32effbe0177
Author: Uwe Brauer <address@hidden>
Date:   Wed Nov 23 22:32:21 2016 +0000

    Add style file for subfiles package.
    
    * Makefile.in (STYLESRC): add subfiles.el entry
    
    * style/subfiles.el ("subfiles"): add new style.
    
    Signed-off-by: Mosè Giordano <address@hidden>

diff --git a/Makefile.in b/Makefile.in
index 6bb7e35..01adbac 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -158,7 +158,7 @@ STYLESRC = style/prosper.el \
           style/pdflscape.el style/commath.el   style/empheq.el \
           style/framed.el    style/paracol.el   style/menukeys.el \
           style/bidi.el      style/FiraMono.el  style/FiraSans.el \
-          style/bicaption.el style/amsfonts.el
+          style/bicaption.el style/amsfonts.el  style/subfiles.el
 
 STYLEELC = $(STYLESRC:.el=.elc)
 
diff --git a/style/subfiles.el b/style/subfiles.el
new file mode 100644
index 0000000..604e4f9
--- /dev/null
+++ b/style/subfiles.el
@@ -0,0 +1,56 @@
+;;; subfiles.el --- AUCTeX style for the subfiles package.
+
+;; Copyright (C) 2016 Free Software Foundation, Inc.
+
+;; Author: Uwe Brauer <address@hidden>
+;; Created: 07 Nov 2016
+;; 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.
+
+;; Acknowledgements
+;; Mosè Giordano  <address@hidden>
+;; Arash Esbati <address@hidden>
+
+;;; Commentary:
+
+;; This file adds support for the subfiles package.
+
+;;; Code:
+
+(defvar LaTeX-subfiles-package-options nil
+  "Package options for the subfiles package.")
+
+(TeX-add-style-hook
+ "subfiles"
+ (lambda ()
+   ;; The following code will fontify `\subfile{}' like  include.
+   (when (and (featurep 'font-latex)
+              (eq TeX-install-font-lock 'font-latex-setup))
+     (font-latex-add-keywords '(("subfile" "{"))
+                              'reference))
+   ;; The following code will run `TeX-run-style-hooks' on the subfile master 
file.
+   ;; Thanks to Mosè Giordano <address@hidden> for presenting a better 
solution using `assoc'.
+   (TeX-run-style-hooks
+    (file-name-base (cadr (assoc "subfiles" LaTeX-provided-class-options))))
+   (TeX-add-symbols
+    '("subfile" TeX-arg-file)))
+ LaTeX-dialect)
+
+
+;;; subfiles.el ends here

-----------------------------------------------------------------------

Summary of changes:
 Makefile.in                        |    2 +-
 style/{setspace.el => subfiles.el} |   52 ++++++++++++++++--------------------
 2 files changed, 24 insertions(+), 30 deletions(-)
 copy style/{setspace.el => subfiles.el} (50%)


hooks/post-receive
-- 
GNU AUCTeX



reply via email to

[Prev in Thread] Current Thread [Next in Thread]