[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
master edabf207: Insert a space between \caption and \\ in tables
From: |
Arash Esbati |
Subject: |
master edabf207: Insert a space between \caption and \\ in tables |
Date: |
Tue, 16 Aug 2022 02:49:29 -0400 (EDT) |
branch: master
commit edabf207b4d66005d3828cb1b5135b7c07e38095
Author: Arash Esbati <arash@gnu.org>
Commit: Arash Esbati <arash@gnu.org>
Insert a space between \caption and \\ in tables
* style/longtable.el (LaTeX-env-longtable):
* style/xltabular.el (LaTeX-env-xltabular): Insert a space between
the end of \caption macro and \\.
---
style/longtable.el | 11 ++++++-----
style/xltabular.el | 11 ++++++-----
2 files changed, 12 insertions(+), 10 deletions(-)
diff --git a/style/longtable.el b/style/longtable.el
index 8db4083c..55384bca 100644
--- a/style/longtable.el
+++ b/style/longtable.el
@@ -88,11 +88,12 @@ insert line break macro."
(insert TeX-grop caption)
;; ask for a label and insert it
(LaTeX-label environment 'environment)
- ;; the longtable `\caption' is equivalent to a
- ;; `\multicolumn', so it needs a `\\' at the
- ;; end of the line. Prior to that, add } to
- ;; close `\caption{'
- (insert TeX-grcl "\\\\")
+ ;; the longtable `\caption' is equivalent to a `\multicolumn',
+ ;; so it needs a `\\' at the end of the line. Prior to that,
+ ;; add } to close `\caption{' and a space:
+ (insert TeX-grcl)
+ (just-one-space)
+ (insert "\\\\")
;; fill the caption
(when auto-fill-function (LaTeX-fill-paragraph))
;; Insert a new line and indent
diff --git a/style/xltabular.el b/style/xltabular.el
index 3fb3e0d2..bcd190b7 100644
--- a/style/xltabular.el
+++ b/style/xltabular.el
@@ -87,11 +87,12 @@ nested curly brace pair nor escaped \"}\".")
(insert TeX-grop caption)
;; ask for a label and insert it
(LaTeX-label environment 'environment)
- ;; the longtable `\caption' is equivalent to a
- ;; `\multicolumn', so it needs a `\\' at the
- ;; end of the line. Prior to that, add } to
- ;; close `\caption{'
- (insert TeX-grcl "\\\\")
+ ;; the longtable `\caption' is equivalent to a `\multicolumn',
+ ;; so it needs a `\\' at the end of the line. Prior to that,
+ ;; add } to close `\caption{' and a space:
+ (insert TeX-grcl)
+ (just-one-space)
+ (insert "\\\\")
;; fill the caption
(when auto-fill-function (LaTeX-fill-paragraph))
;; Insert a new line and indent
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- master edabf207: Insert a space between \caption and \\ in tables,
Arash Esbati <=