help-gnu-emacs
[Top][All Lists]
Advanced

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

question concerning overlay before-strings and property inheritance


From: az
Subject: question concerning overlay before-strings and property inheritance
Date: Mon, 25 Apr 2011 20:34:54 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

Is there any way to arrange for an overlay before-string to inherit 
face properties from other overlays?  

Evaluation of the following form provides a test case of my problem: 

(save-excursion
  (goto-char 1)
  (insert ";; String\n")
  (let ((o (make-overlay 6 7))
        (o2 (make-overlay 4 8)))
    (overlay-put o 'before-string "FOO")
    (overlay-put o2 'face 'highlight)))

As you can see, the before-string "FOO" doesn't inherit any
highlighting from the second overlay.  Is it possible to set up
the overlays up so that the before-string inherits the face
property from the second overlay?  (I know I can manually
propertize the before-string with the relevant face, but I'd
like, if possible, to arrange for the face inheritance to happen
automatically.)







reply via email to

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