I'm running Emacs 23.3.1 on Mac OS X. When I have linum-mode enable some lines are not numbered. Sometimes when my cursor scrolls past a line that is not numbered its number will appear and then sometimes it will disappear again. Is there away to prevent this from happening?
From your screenshot, it looks like lines with only comments are not numbered. Dunno why.
Perhaps there is another overlay at such positions, and it has a higher priority, thus masking the line-number overlay. Try turning off font-lock temporarily, to see whether that affects things. Then try increasing the priority of the line-number overlays. For a quick test, do this:
(defun foo () (dolist (ov linum-overlays) (overlay-put ov 'priority 2000))) (add-to-list 'post-command-hook 'foo t t)
If that helps, then instead of that, do the overlay-put
(but try with a ower priority, say, 200) in function linum-update-window
. IOW, add the priority when the overlay is put on the text.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.