emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/latex-table-wizard 85af90dac4 52/70: Use TeX-comment-fo


From: ELPA Syncer
Subject: [elpa] externals/latex-table-wizard 85af90dac4 52/70: Use TeX-comment-forward
Date: Sat, 13 May 2023 08:59:14 -0400 (EDT)

branch: externals/latex-table-wizard
commit 85af90dac4b44ed7333a6aa95512220398dd4b32
Author: Enrico Flor <nericoflor@gmail.com>
Commit: Enrico Flor <nericoflor@gmail.com>

    Use TeX-comment-forward
---
 latex-table-wizard.el | 16 +++++-----------
 1 file changed, 5 insertions(+), 11 deletions(-)

diff --git a/latex-table-wizard.el b/latex-table-wizard.el
index d9a3bd2c36..6771206bd3 100644
--- a/latex-table-wizard.el
+++ b/latex-table-wizard.el
@@ -247,8 +247,8 @@ If NAME is nil, skip any LaTeX macro that point is looking 
at."
         ;; skips stuff that is not a LaTeX argument group.
         (while (looking-at-p "{\\|\\[")
           (forward-sexp)
-          (when (looking-at "[[:space:]]*\\(%.*\n\\)?[[:space:]]*")
-            (goto-char (match-end 0))))
+          (TeX-comment-forward 1)
+          (skip-syntax-forward " "))
         ;; now we have moved too far ahead looking for arguments,
         ;; let's jump back all the whitespace
         (skip-syntax-backward " ")
@@ -313,12 +313,8 @@ argument."
         (end)
         (end-of-row))
     (while (and (< (point) lim) (not end))
-      (cond ((and (looking-at "%")
-                  (not (TeX-escaped-p)))
-             ;; the first step is important to avoid being fooled by
-             ;; column or row delimiters in comments!
-             (forward-line))
-            ((looking-at-p "[[:space:]]+")
+      (TeX-comment-forward 1)
+      (cond ((looking-at-p "[[:space:]]+")
              (skip-syntax-forward " "))
             ((and (not (TeX-escaped-p))
                   (looking-at-p "\\\\begin\\({\\|\\[\\)"))
@@ -412,9 +408,7 @@ Each value is an integer, S and E are markers."
             (forward-char 1)
           (insert " "))
         (while (< (point) env-end)
-          (when (looking-at-p "[[:space:]]*\\($\\|%\\)")
-            ;; nothing interesting left between point and eol
-            (forward-line))
+          (TeX-comment-forward 1)
           (let ((data (latex-table-wizard--get-cell-boundaries
                        col-re row-re env-end)))
             (push `( :column ,col



reply via email to

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