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

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

[nongnu] elpa/jade-mode 3db33f4642 050/128: Fixed sws-indent-line not de


From: ELPA Syncer
Subject: [nongnu] elpa/jade-mode 3db33f4642 050/128: Fixed sws-indent-line not detecting the use of tab indent
Date: Sat, 29 Jan 2022 08:24:46 -0500 (EST)

branch: elpa/jade-mode
commit 3db33f4642f7b731771e868edce7c138c05a17a5
Author: Jaakko Pallari <jkpl@lepovirta.org>
Commit: Jaakko Pallari <jkpl@lepovirta.org>

    Fixed sws-indent-line not detecting the use of tab indent
---
 sws-mode.el | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/sws-mode.el b/sws-mode.el
index 84f9a74a85..094211490b 100644
--- a/sws-mode.el
+++ b/sws-mode.el
@@ -47,14 +47,13 @@
 (defun sws-indent-line ()
   "Indents current line"
   (interactive)
-  (if (and (eq (current-indentation) 0)
-           (not (eq last-command 'sws-indent-line)))
-      (indent-to (sws-previous-indentation))
+  (if (eq this-command 'indent-for-tab-command)
     (if mark-active
         (sws-indent-region (region-beginning) (region-end))
       (if (sws-at-bot-p)
           (sws-do-indent-line)
-        (sws-point-to-bot)))))
+        (sws-point-to-bot)))
+    (indent-to (sws-previous-indentation))))
 
 (defun sws-at-bol-p ()
   "If point is at beginning of line"



reply via email to

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