emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

overlays with display and window property


From: martin rudalics
Subject: overlays with display and window property
Date: Sun, 28 Aug 2005 11:15:13 +0200
User-agent: Mozilla Thunderbird 1.0 (Windows/20041206)

The Emacs Lisp manual specifies the window property of an overlay as:

`window'
     If the `window' property is non-`nil', then the overlay applies
     only on that window.

This works well with most overlay properties.  Executing

(defun foobar ()
  (interactive)
  (insert "foo")
  (let ((overlay (make-overlay (- (point) 3) (point))))
    (overlay-put overlay 'window (selected-window))
    (overlay-put overlay 'display "bar")
    (split-window)))

however, displays "bar" in both windows.  According to the manual "bar"
should replace "foo" in the initially selected window only.





reply via email to

[Prev in Thread] Current Thread [Next in Thread]