aboutsummaryrefslogtreecommitdiff
path: root/evil-vars.el
diff options
context:
space:
mode:
authorTom Dalziel <33435574+tomdl89@users.noreply.github.com>2021-10-04 21:40:30 +0200
committerGitHub <noreply@github.com>2021-10-04 21:40:30 +0200
commitcb39d3dc9f0806366e8a37a61ff967fa329b78a2 (patch)
tree38b8e39e8b6fd48cbf75937f07647f5542e6624d /evil-vars.el
parent82e5becae21b7768ffbb4728bce83dab8751d610 (diff)
Add evil-start-of-line, evil-ensure-column, and use them (#1524)
Diffstat (limited to 'evil-vars.el')
-rw-r--r--evil-vars.el10
1 files changed, 10 insertions, 0 deletions
diff --git a/evil-vars.el b/evil-vars.el
index c8add73..d516ef1 100644
--- a/evil-vars.el
+++ b/evil-vars.el
@@ -204,6 +204,13 @@ cursor, or a list of the above."
(defvar evil-force-cursor nil
"Overwrite the current states default cursor.")
+(defcustom evil-start-of-line nil
+ "Analogue of vim's `startofline'.
+If nil, preserve column when making relevant movements of the cursor.
+Otherwise, move the cursor to the start of the line."
+ :type 'boolean
+ :group 'evil)
+
(defcustom evil-repeat-move-cursor t
"\\<evil-normal-state-map>
Whether repeating commands with \\[evil-repeat] may move the cursor.
@@ -1440,6 +1447,9 @@ of `evil-inhibit-operator' from one local scope to another.")
(defvar evil-operator-range-motion nil
"Motion of `evil-operator-range'.")
+(defvar evil-operator-start-col nil
+ "Used to restore column (where possible) after an operator has moved it.")
+
(defvar evil-restriction-stack nil
"List of previous restrictions.
Using `evil-with-restriction' stores the previous values of