[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[AUCTeX-diffs] [elpa] externals/auctex 2e9b714 09/25: Add new style/foot
From: |
Tassilo Horn |
Subject: |
[AUCTeX-diffs] [elpa] externals/auctex 2e9b714 09/25: Add new style/footnotehyper.el |
Date: |
Sun, 21 Mar 2021 11:44:40 -0400 (EDT) |
branch: externals/auctex
commit 2e9b714d96db06ebd644639a153fc9fd98126a2f
Author: Arash Esbati <arash@gnu.org>
Commit: Arash Esbati <arash@gnu.org>
Add new style/footnotehyper.el
* Makefile.in (STYLESRC): Add new style.
* style/footnotehyper.el ("footnotehyper"): New file.
---
Makefile.in | 2 +-
style/footnotehyper.el | 86 ++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 87 insertions(+), 1 deletion(-)
diff --git a/Makefile.in b/Makefile.in
index 671ae2c..8822ae4 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -174,7 +174,7 @@ STYLESRC = style/prosper.el \
style/ltxguide.el style/revtex4-2.el style/overpic.el \
style/tex-live.el style/algorithm.el style/algpseudocode.el \
style/appendix.el style/scholax.el style/extramarks.el \
- style/truncate.el
+ style/truncate.el style/footnotehyper.el
STYLEELC = $(STYLESRC:.el=.elc)
diff --git a/style/footnotehyper.el b/style/footnotehyper.el
new file mode 100644
index 0000000..d97e5b2
--- /dev/null
+++ b/style/footnotehyper.el
@@ -0,0 +1,86 @@
+;;; footnotehyper.el --- AUCTeX style for `footnotehyper.sty' -*-
lexical-binding: t; -*-
+
+;; Copyright (C) 2021 Free Software Foundation, Inc.
+
+;; Author: Arash Esbati <arash@gnu.org>
+;; Maintainer: auctex-devel@gnu.org
+;; Created: 2021-01-31
+;; 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 Street, Fifth Floor, Boston,
+;; MA 02110-1301 USA.
+
+;;; Commentary:
+
+;; This file adds support for `footnotehyper.sty'.
+
+;;; Code:
+
+(require 'tex)
+
+;; Silence the compiler:
+(declare-function font-latex-add-keywords
+ "font-latex"
+ (keywords class))
+
+(defun LaTeX-arg-footnotehyper-savenotes (_optional)
+ "Insert the corresponding \\spewnotes macro after \\savenotes.
+OPTIONAL is ignored."
+ (just-one-space)
+ (save-excursion
+ (insert TeX-esc "spewnotes")))
+
+(TeX-add-style-hook
+ "footnotehyper"
+ (lambda ()
+
+ ;; Environment defined by the package. Query for optional footnote
+ ;; numbers depends on the value of `TeX-arg-footnote-number-p':
+ (LaTeX-add-environments
+ '("savenotes")
+ '("footnote" LaTeX-env-args
+ (TeX-arg-conditional TeX-arg-footnote-number-p ([ "Number" ]) nil))
+ '("footnotetext" LaTeX-env-args
+ (TeX-arg-conditional TeX-arg-footnote-number-p ([ "Number" ]) nil)))
+
+ ;; New symbols
+ (TeX-add-symbols
+ '("savenotes" LaTeX-arg-footnotehyper-savenotes)
+ '("spewnotes" 0)
+
+ ;; The syntax is \makesavenoteenv[bar]{foo} where `bar' is a new
+ ;; environment of patched environment `foo'. This command isn't
+ ;; recommended; hence we don't add parsing capabilities to this
+ ;; style in order to extract the newly defined environments
+ ;; automatically:
+ '("makesavenoteenv"
+ [TeX-arg-environment "New environment" t]
+ (TeX-arg-environment "Patched environment")))
+
+ ;; Fontification
+ (when (and (featurep 'font-latex)
+ (eq TeX-install-font-lock 'font-latex-setup))
+ (font-latex-add-keywords '(("savenotes" "")
+ ("spewnotes" "")
+ ("makesavenoteenv" "[{"))
+ 'function)))
+ TeX-dialect)
+
+(defvar LaTeX-footnotehyper-package-options nil
+ "Package options for the footnotehyper package.")
+
+;;; footnotehyper.el ends here
- [AUCTeX-diffs] [elpa] externals/auctex updated (04d69c5 -> 48fb645), Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 42f1bc3 03/25: ; Fix texinfo error, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 0e616b8 16/25: Enable lexical binding in plain-tex.el, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 653e272 12/25: Deprioritize "\\.drv\\'" in auto-mode-alist, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 39c4e77 07/25: Add new style/truncate.el, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex f87d90f 02/25: Document how to load AUCTeX from a local Git repo, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 8bc74dd 01/25: Update style/bigdelim.el to package version 2.6, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 4384639 11/25: Add new style/changes.el, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 2e9b714 09/25: Add new style/footnotehyper.el,
Tassilo Horn <=
- [AUCTeX-diffs] [elpa] externals/auctex 331b24c 21/25: Use "wrap region or query for logo" also in \[hH]ologoVariant, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 737fa11 20/25: Fix wrapping of active region with \[Hh]ologo macros, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 5afcc09 10/25: Add parsing support to style/comment.el, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 2848def 14/25: * style/geometry.el ("geometry"): Fontify \restoregeometry macro., Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex da52023 24/25: Discard `TeX-auto-update' to silence byte compiler, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 72e645f 13/25: ; * tex-buf.el (TeX-active-master): Fix comment., Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 6db8a1a 06/25: ; Use @subsection, Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex b9f4f36 04/25: ; * doc/quickstart.texi (Editing Facilities): Fix formatting., Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 0c90254 15/25: ; * tex-buf.el (TeX-command-region): Fix typo in comment., Tassilo Horn, 2021/03/21
- [AUCTeX-diffs] [elpa] externals/auctex 18bc7b6 18/25: Enable lexical binding in context-{en, nl}.el, Tassilo Horn, 2021/03/21