[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/auctex 5cf1dd2ae2 01/13: Indent the active region (bug#
From: |
Tassilo Horn |
Subject: |
[elpa] externals/auctex 5cf1dd2ae2 01/13: Indent the active region (bug#48518, bug#28382) |
Date: |
Sun, 5 Mar 2023 03:25:39 -0500 (EST) |
branch: externals/auctex
commit 5cf1dd2ae2cce3393481138fe57392aab14256ef
Author: Ikumi Keita <ikumi@ikumi.que.jp>
Commit: Ikumi Keita <ikumi@ikumi.que.jp>
Indent the active region (bug#48518, bug#28382)
* latex.el (LaTeX-insert-environment): Indent the active region so
that indentation isn't broken even in nested environments.
(LaTeX-env-label): Remove indentation code no longer necessary by the
above change.
---
latex.el | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/latex.el b/latex.el
index 56992d54fb..fb862b7637 100644
--- a/latex.el
+++ b/latex.el
@@ -821,12 +821,13 @@ environment just inserted, the buffer position just before
(end-of-line 0)
(if active-mark
(progn
- (or (assoc environment LaTeX-indent-environment-list)
- (if auto-fill-function
- ;; Fill the region only when `auto-fill-mode' is active.
- (LaTeX-fill-region content-start (line-beginning-position 2))
- ;; Else just indent the region. (bug#48518)
- (indent-region content-start (line-beginning-position 2))))
+ (if (and auto-fill-function
+ (not (assoc environment LaTeX-indent-environment-list)))
+ ;; Fill the region only when `auto-fill-mode' is active
+ ;; and no special indent rule exists.
+ (LaTeX-fill-region content-start (line-beginning-position 2))
+ ;; Else just indent the region. (bug#48518, bug#28382)
+ (indent-region content-start (line-beginning-position 2)))
(set-mark content-start))
(indent-according-to-mode))
;; Indent \end{foo}.
@@ -1335,7 +1336,6 @@ Just like array and tabular."
(LaTeX-newline)
(indent-according-to-mode))
(when (TeX-active-mark)
- (indent-region (point) (mark))
;; Restore the positions of point and mark.
(exchange-point-and-mark)))
- [elpa] externals/auctex updated (6d4b412b69 -> 658832b8a2), Tassilo Horn, 2023/03/05
- [elpa] externals/auctex 41397e93cb 04/13: ; Improve last change, Tassilo Horn, 2023/03/05
- [elpa] externals/auctex 5cf1dd2ae2 01/13: Indent the active region (bug#48518, bug#28382),
Tassilo Horn <=
- [elpa] externals/auctex 3564d9467e 10/13: ; Fix typos, Tassilo Horn, 2023/03/05
- [elpa] externals/auctex 992410a201 02/13: ; * style/physics.el: Fix trivial typo., Tassilo Horn, 2023/03/05
- [elpa] externals/auctex 9d8bd6b30e 06/13: Update style/ltugboat.el to class version 2.28, Tassilo Horn, 2023/03/05
- [elpa] externals/auctex fbc6399b99 09/13: Add new tests, Tassilo Horn, 2023/03/05
- [elpa] externals/auctex b77907698e 12/13: Merge remote-tracking branch 'origin/master' into externals/auctex, Tassilo Horn, 2023/03/05
- [elpa] externals/auctex bbb4e2ae23 08/13: Fill \verb-like macros appropriately (bug#61400), Tassilo Horn, 2023/03/05
- [elpa] externals/auctex 658832b8a2 13/13: Release GNU AUCTeX 13.1.10, Tassilo Horn, 2023/03/05
- [elpa] externals/auctex 358cc74dda 03/13: Add new style/algpseudocodex.el, Tassilo Horn, 2023/03/05
- [elpa] externals/auctex de6aa05d74 05/13: Make `texmathp' aware of verbatim macros/environments, Tassilo Horn, 2023/03/05
- [elpa] externals/auctex 4c77908707 11/13: Fix \includegraphics key-vals prompt in beamer documents., Tassilo Horn, 2023/03/05