You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Here is the change that I made to make linum-relative respect user's format:
diff --git a/elpa/linum-relative-20131210.2053/linum-relative.el b/elpa/linum-relative-20131210.2053/linum-relative.el
index 1da995b..8e6c356 100644
--- a/elpa/linum-relative-20131210.2053/linum-relative.el+++ b/elpa/linum-relative-20131210.2053/linum-relative.el@@ -80,6 +80,8 @@ linum-releative will show the real line number at current line."
(defvar linum-relative-last-pos 0
"Store last position.")
+(defvar user-format 'dynamic+ "Store user format")
;;;; Advices
(defadvice linum-update (before relative-linum-update activate)
"This advice get the last position of linum."
@@ -103,9 +105,10 @@ linum-releative will show the real line number at current line."
(defun linum-relative-toggle ()
"Toggle between linum-relative and linum."
(interactive)
- (if (eq linum-format 'dynamic)- (setq linum-format 'linum-relative)- (setq linum-format 'dynamic)))+ (if (eq linum-format 'linum-relative)+ (setq linum-format user-format)+ (setq user-format linum-format)+ (setq linum-format 'linum-relative)))
(setq linum-format 'linum-relative)
When toggling on/off
linum-relative
, it removes user setting forlinum-format
. User option should be reserved.The text was updated successfully, but these errors were encountered: