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. 25fe7295d21de4231d5e7


From: Mosè Giordano
Subject: [AUCTeX-diffs] GNU AUCTeX branch, master, updated. 25fe7295d21de4231d5e7d5a890b4529d06f1eda
Date: Fri, 04 Apr 2014 19:54:30 +0000

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  25fe7295d21de4231d5e7d5a890b4529d06f1eda (commit)
      from  353eb2a490d642d9f4b707213a9c3fcb2fa2997e (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 25fe7295d21de4231d5e7d5a890b4529d06f1eda
Author: Mosè Giordano <address@hidden>
Date:   Fri Apr 4 21:46:07 2014 +0200

    Use LaTeX-biblatex-use-Biber to manually select bibliography processor.
    
    * tex-style.el: Update coyright years.
    (LaTeX-biblatex-use-Biber): New variable.  Mark as
    safe-local-variable.
    
    * latex.el (TeX-latex-mode): Add setting of `LaTeX-using-Biber' to
    `TeX-update-style-hook'.
    
    * style/biblatex.el ("biblatex"): Use `LaTeX-biblatex-use-Biber'
    value to set `LaTeX-using-Biber' when it is set locally.
    
    * tex-bar.el: Update copyright years.
    (LaTeX-install-toolbar): Append toolbar refresh to
    `TeX-update-style-hook' instead of prepending it.
    
    * doc/auctex.texi:  Update copyright years.
    (Selecting a Command): Document `LaTeX-biblatex-use-Biber'.
    
    * doc/changes.texi: Mention `LaTeX-biblatex-use-Biber' change.

diff --git a/ChangeLog b/ChangeLog
index e024f95..e840622 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,24 @@
+2014-04-04  Mosè Giordano  <address@hidden>
+
+       * tex-style.el: Update coyright years.
+       (LaTeX-biblatex-use-Biber): New variable.  Mark as
+       safe-local-variable.
+
+       * latex.el (TeX-latex-mode): Add setting of `LaTeX-using-Biber' to
+       `TeX-update-style-hook'.
+
+       * style/biblatex.el ("biblatex"): Use `LaTeX-biblatex-use-Biber'
+       value to set `LaTeX-using-Biber' when it is set locally.
+
+       * tex-bar.el: Update copyright years.
+       (LaTeX-install-toolbar): Append toolbar refresh to
+       `TeX-update-style-hook' instead of prepending it.
+
+       * doc/auctex.texi:  Update copyright years.
+       (Selecting a Command): Document `LaTeX-biblatex-use-Biber'.
+
+       * doc/changes.texi: Mention `LaTeX-biblatex-use-Biber' change.
+
 2014-04-02  Mosè Giordano  <address@hidden>
 
        * style/biblatex.el: Update copyright years and specify last
diff --git a/doc/auctex.texi b/doc/auctex.texi
index 88fc820..c84282a 100644
--- a/doc/auctex.texi
+++ b/doc/auctex.texi
@@ -12,7 +12,7 @@ This manual is for @AUCTeX{}
 (version @value{VERSION} from @value{UPDATED}),
 a sophisticated TeX environment for Emacs.
 
-Copyright @copyright{} 1992-1995, 2001, 2002, 2004-2013
+Copyright @copyright{} 1992-1995, 2001, 2002, 2004-2014
 Free Software Foundation, Inc.
 
 @quotation
@@ -2696,11 +2696,18 @@ The default command to run in this buffer.  Must be an 
entry in
 
 @cindex Biber
 @cindex biblatex
-In case you use biblatex in a document, @AUCTeX{} switches from
address@hidden to Biber for bibliography processing.  If you have enabled
-automatic parsing, @AUCTeX{} checks the value of @samp{backend} option
-given to biblatex at load time to decide whether to use address@hidden or
-Biber.
+In case you use biblatex in a document, when automatic parsing is
+enabled @AUCTeX{} checks the value of @samp{backend} option given to
+biblatex at load time to decide whether to use address@hidden or Biber for
+bibliography processing.  Should @AUCTeX{} fail to detect the right
+backend, you can use the file local @code{LaTeX-biblatex-use-Biber}
+variable.
address@hidden Variable LaTeX-biblatex-use-Biber
+If this boolean variable is set as file local, it tells to @AUCTeX{}
+whether to use Biber with biblatex.  In this case, the autodetection of
+the biblatex backend will be overridden.  You may want to set locally
+this variable if automatic parsing is not enabled.
address@hidden defvr
 
 After confirming a command to execute, @AUCTeX{} will try to save any
 buffers related to the document, and check if the document needs to be
diff --git a/doc/changes.texi b/doc/changes.texi
index a324dcb..b8eb96a 100644
--- a/doc/changes.texi
+++ b/doc/changes.texi
@@ -51,7 +51,8 @@ and @code{LaTeX-fontspec-font-list-default}.  A new possible 
value
 @item
 @samp{biblatex} support was greatly expanded.  If parsing is enabled,
 @AUCTeX{} looks at @samp{backend} option to decide whether to use Biber
-or BibTeX.  @code{LaTeX-biblatex-use-Biber} option was removed.
+or BibTeX.  The @code{LaTeX-biblatex-use-Biber} variable was changed to
+be file local only and is no more customizable.
 
 @item
 With some @LaTeX{} classes, the default environment suggested by
diff --git a/latex.el b/latex.el
index 69e8760..4b9188a 100644
--- a/latex.el
+++ b/latex.el
@@ -5535,6 +5535,14 @@ of `LaTeX-mode-hook'."
            (featurep 'toolbar)
          (and (boundp 'tool-bar-mode) tool-bar-mode))
     (LaTeX-maybe-install-toolbar))
+  ;; Set the value of `LaTeX-using-Biber' based on the local value of
+  ;; `LaTeX-biblatex-use-Biber'.  This should be run within
+  ;; `TeX-update-style-hook' before toolbarx-refresh, otherwise the 
bibliography
+  ;; button could be wrongly set.
+  (add-hook 'TeX-update-style-hook
+           (lambda ()
+             (if (local-variable-p 'LaTeX-biblatex-use-Biber)
+                 (setq LaTeX-using-Biber LaTeX-biblatex-use-Biber))) nil t)
   (TeX-run-mode-hooks 'text-mode-hook 'TeX-mode-hook 'LaTeX-mode-hook)
   (TeX-set-mode-name)
   ;; Defeat filladapt
diff --git a/style/biblatex.el b/style/biblatex.el
index 600e149..ff2d7d6 100644
--- a/style/biblatex.el
+++ b/style/biblatex.el
@@ -220,11 +220,18 @@ for citation keys."
  "biblatex"
  (lambda ()
    ;; Biblatex uses as default backend biber, run it unless biblatex `backend'
-   ;; option value is one of `bibtex', `bibtex8', `bibtexu'.
+   ;; option value is one of `bibtex', `bibtex8', `bibtexu'.  Autodetection of
+   ;; the backend can be overridden by setting `LaTeX-biblatex-use-Biber' as a
+   ;; local variable.
    (setq LaTeX-using-Biber
-        (not (or (LaTeX-provided-package-options-member "biblatex" 
"backend=bibtex")
-                 (LaTeX-provided-package-options-member "biblatex" 
"backend=bibtex8")
-                 (LaTeX-provided-package-options-member "biblatex" 
"backend=bibtexu"))))
+        (if (local-variable-p 'LaTeX-biblatex-use-Biber)
+            LaTeX-biblatex-use-Biber
+          (not (or (LaTeX-provided-package-options-member
+                    "biblatex" "backend=bibtex")
+                   (LaTeX-provided-package-options-member
+                    "biblatex" "backend=bibtex8")
+                   (LaTeX-provided-package-options-member
+                    "biblatex" "backend=bibtexu")))))
 
    (TeX-run-style-hooks
     "etoolbox"
diff --git a/tex-bar.el b/tex-bar.el
index aaa9301..f3cbaf1 100644
--- a/tex-bar.el
+++ b/tex-bar.el
@@ -1,6 +1,6 @@
 ;;; tex-bar.el --- toolbar icons on AUCTeX in GNU emacs and XEmacs
 
-;; Copyright (C) 2004-2008, 2012, 2013 Free Software Foundation, Inc.
+;; Copyright (C) 2004-2008, 2012-2014 Free Software Foundation, Inc.
 
 ;; This program is free software; you can redistribute it and/or
 ;; modify it under the terms of the GNU General Public License as
@@ -371,9 +371,10 @@ format of the argument MEANING-ALIST in the mentioned 
function."
   (add-to-list 'toolbarx-image-path
               (expand-file-name "images" TeX-data-directory))
   (add-hook 'TeX-PDF-mode-hook 'toolbarx-refresh nil t)
-  ;; Refresh toolbar after styles update because `LaTeX-using-Biber' value 
could
-  ;; have been changed.
-  (add-hook 'TeX-update-style-hook 'toolbarx-refresh nil t)
+  ;; Refresh the toolbar after styles update because `LaTeX-using-Biber' value
+  ;; could have been changed.  Append the refresh to the hook so it is run 
after
+  ;; the other styles-related changes.
+  (add-hook 'TeX-update-style-hook 'toolbarx-refresh t t)
   (toolbarx-install-toolbar TeX-bar-LaTeX-buttons
                            (let ((append-list))
                              (dolist (elt TeX-bar-LaTeX-all-button-alists)
diff --git a/tex-style.el b/tex-style.el
index 9975b3f..b03a004 100644
--- a/tex-style.el
+++ b/tex-style.el
@@ -1,6 +1,7 @@
 ;;; tex-style.el --- Customizable variables for AUCTeX style files
 
-;; Copyright (C) 2005, 2013  Free Software Foundation, Inc.
+;; Copyright (C) 2005, 2007, 2009, 2012-2014
+;;   Free Software Foundation, Inc.
 
 ;; Author: Reiner Steib <address@hidden>
 ;; Keywords: tex, wp, convenience
@@ -213,6 +214,16 @@ It can be a list of themes or a function.  If it is the 
symbol
             :tag "Other"
             (string)))))
 
+;; style/biblatex.el
+
+(defvar LaTeX-biblatex-use-Biber t
+  "Whether to use Biber with biblatex.
+
+This variable is intended to be used as a file local variable to
+override the autodetection of the biblatex backend.")
+(make-variable-buffer-local 'LaTeX-biblatex-use-Biber)
+(put 'LaTeX-biblatex-use-Biber 'safe-local-variable 'TeX-booleanp)
+
 ;; style/comment.el
 
 (defcustom LaTeX-comment-env-list '("comment")

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

Summary of changes:
 ChangeLog         |   21 +++++++++++++++++++++
 doc/auctex.texi   |   19 +++++++++++++------
 doc/changes.texi  |    3 ++-
 latex.el          |    8 ++++++++
 style/biblatex.el |   15 +++++++++++----
 tex-bar.el        |    9 +++++----
 tex-style.el      |   13 ++++++++++++-
 7 files changed, 72 insertions(+), 16 deletions(-)


hooks/post-receive
-- 
GNU AUCTeX



reply via email to

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