emacs-devel
[Top][All Lists]
Advanced

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

Re: Emacs Lisp manual issues regarding overlays, display properties, mar


From: Johan Bockgård
Subject: Re: Emacs Lisp manual issues regarding overlays, display properties, margins, etc.
Date: Tue, 02 Oct 2007 18:07:22 +0200
User-agent: Gnus/5.110007 (No Gnus v0.7) Emacs/22.1.50 (gnu/linux)

Richard Stallman <address@hidden> writes:

> There seems to be something totally fishy with the way margin display
> properties work:
>
>       (test-overlays
>        (insert "ABC")
>        (let ((o1 (make-overlay 2 3)))
>        (overlay-put o1 'display '((margin left-margin) "Z")))
>        (set-window-margins (get-buffer-window (current-buffer)) 8))
>
> this causes Z to appear in the margin and causes B not to appear
> in the body of the text.
>
> That seems like a bug to me.  It seems to me that a property that puts
> something in the margin should not alter the appearance of the text
> it is on.
>
> Does anyone think the current behavior is desirable?

In any case, it follows the documentation

    If you put such a display specification directly on text in the
    buffer, the specified margin display appears _instead of_ that
    buffer text itself. To put something in the margin _in association
    with_ certain buffer text without preventing or altering the display
    of that text, put a `before-string' property on the text and put the
    display specification on the contents of the before-string.

(info "(elisp)Display Margins")

-- 
Johan Bockgård





reply via email to

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