Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@guehara
Created May 14, 2012 08:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save guehara/2692728 to your computer and use it in GitHub Desktop.
Save guehara/2692728 to your computer and use it in GitHub Desktop.
linum-mode で行数に応じて幅を調整
;; linum
(require 'linum)
(setq linum-format
(lambda (line) (propertize (format (let ((w (length (number-to-string (count-lines (point-min) (point-max)))))) (concat "%" (number-to-string w) "d")) line) 'face 'linum)))
(global-linum-mode t)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment