changeset 106225:5418676a97db

(linum-update-window): Ignore intangible (bug#4996).
author Stefan Monnier <monnier@iro.umontreal.ca>
date Tue, 24 Nov 2009 22:28:01 +0000
parents 647b4d392557
children 85863d02e2db
files lisp/ChangeLog lisp/linum.el
diffstat 2 files changed, 8 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/ChangeLog	Tue Nov 24 22:23:49 2009 +0000
+++ b/lisp/ChangeLog	Tue Nov 24 22:28:01 2009 +0000
@@ -1,3 +1,7 @@
+2009-11-24  Markus Triska  <markus.triska@gmx.at>
+
+	* linum.el (linum-update-window): Ignore intangible (bug#4996).
+
 2009-11-24  Stefan Monnier  <monnier@iro.umontreal.ca>
 
 	Handle the [back] button properly (bug#4979).
--- a/lisp/linum.el	Tue Nov 24 22:23:49 2009 +0000
+++ b/lisp/linum.el	Tue Nov 24 22:28:01 2009 +0000
@@ -166,7 +166,10 @@
             (overlay-put ov 'before-string
                          (propertize " " 'display `((margin left-margin) ,str)))
             (overlay-put ov 'linum-str str))))
-      (forward-line)
+      ;; Text may contain those nasty intangible properties, but that
+      ;; shouldn't prevent us from counting those lines.
+      (let ((inhibit-point-motion-hooks t))
+        (forward-line))
       (setq line (1+ line)))
     (set-window-margins win width (cdr (window-margins win)))))