[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/auctex 835e01ddb6 36/48: Extend the argument list of `T
From: |
Tassilo Horn |
Subject: |
[elpa] externals/auctex 835e01ddb6 36/48: Extend the argument list of `TeX-arg-string' |
Date: |
Fri, 18 Nov 2022 14:27:45 -0500 (EST) |
branch: externals/auctex
commit 835e01ddb6d25984edc33e44df7ea102c64be8b3
Author: Arash Esbati <arash@gnu.org>
Commit: Arash Esbati <arash@gnu.org>
Extend the argument list of `TeX-arg-string'
* tex.el (TeX-arg-string): Extend the argument list which will be
passed to `TeX-read-string' and change the brackets for insertion.
---
tex.el | 29 ++++++++++++++++++++---------
1 file changed, 20 insertions(+), 9 deletions(-)
diff --git a/tex.el b/tex.el
index 5cb86af1f1..7fe8095aba 100644
--- a/tex.el
+++ b/tex.el
@@ -3451,18 +3451,29 @@ TeX macro. What is done depend on the type of the
element:
(insert TeX-grcl)
(backward-char))))))))
-(defun TeX-arg-string (optional &optional prompt initial-input)
+(defun TeX-arg-string (optional &optional prompt initial-input
+ history default-value
+ leftbrace rightbrace)
"Prompt for a string.
If OPTIONAL is not nil then the PROMPT will start with ``(Optional) ''.
-INITIAL-INPUT is a string to insert before reading input."
- (TeX-argument-insert
- (if (and (not optional) (TeX-active-mark))
- (let ((TeX-argument (buffer-substring (point) (mark))))
- (delete-region (point) (mark))
- TeX-argument)
- (TeX-read-string (TeX-argument-prompt optional prompt "Text")
initial-input))
- optional))
+INITIAL-INPUT is a string to insert before reading input.
+
+HISTORY and DEFAULT-VALUE are ultimately passed to `read-string',
+which see.
+
+The brackets used are controlled by the string values of
+LEFTBRACE and RIGHTBRACE."
+ (let ((TeX-arg-opening-brace (or leftbrace TeX-arg-opening-brace))
+ (TeX-arg-closing-brace (or rightbrace TeX-arg-closing-brace)))
+ (TeX-argument-insert
+ (if (and (not optional) (TeX-active-mark))
+ (let ((TeX-argument (buffer-substring (point) (mark))))
+ (delete-region (point) (mark))
+ TeX-argument)
+ (TeX-read-string (TeX-argument-prompt optional prompt "Text")
+ initial-input history default-value))
+ optional)))
(defvar TeX-last-optional-rejected nil
"Dynamically bound by `TeX-parse-arguments'.")
- [elpa] externals/auctex c6c7c3f024 22/48: ; Use #' to quote function, (continued)
- [elpa] externals/auctex c6c7c3f024 22/48: ; Use #' to quote function, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex c0c9556338 30/48: Don't insert empty node name, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 978ebea1e8 16/48: Simplify implementation of style/thmtools.el, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex d3970b77da 09/48: ; * latex.el (LaTeX-common-initialization): Remove dupe textcircled., Tassilo Horn, 2022/11/18
- [elpa] externals/auctex a0ba387b2c 23/48: ; Trivial cleanups, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 04a3138c81 45/48: Simplify implementation of style/theorem.el, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 316550f0bf 29/48: Fix `ConTeXt-add-environments', Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 8775c8355f 13/48: Replace `TeX-arg-url-urlstyle' in style/url.el, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex a7a7209a08 33/48: Extend the argument list of some functions, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex c8d638ac9d 40/48: Use `functionp' to recognize a function, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 835e01ddb6 36/48: Extend the argument list of `TeX-arg-string',
Tassilo Horn <=
- [elpa] externals/auctex e83a4b87b3 25/48: Use the correct function to retrieve the key=vals, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex a617944b4b 08/48: Fix style/xspace.el, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 50c0fb3d31 46/48: * style/afterpage.el ("afterpage"): Fontify the only macro., Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 82a23a93ae 43/48: Add some variables containing font declarations, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 93430d7ab0 48/48: Merge remote-tracking branch 'origin/master' into externals/auctex, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 7642155b73 03/48: Don't let-bind `inhibit-point-motion-hooks' to t, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 6cbeff713b 47/48: Simplify implementation of style/fancyhdr.el, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 3d8d93e4fd 41/48: ; Make code more resilient, Tassilo Horn, 2022/11/18
- [elpa] externals/auctex 35ec84ba6f 07/48: Add capf for LaTeX marco/environment arguments, Tassilo Horn, 2022/11/18