From: "Andreas Röhler" <andreas.roehler@online.de>
To: emacs-devel@gnu.org
Cc: Eli Zaretskii <eliz@gnu.org>
Subject: Re: Nested display strings
Date: Sat, 23 Apr 2011 21:42:14 +0200 [thread overview]
Message-ID: <4DB32B96.50409@online.de> (raw)
In-Reply-To: <83k4ekc3z1.fsf@gnu.org>
Am 23.04.2011 18:44, schrieb Eli Zaretskii:
> The following 4 lines define two overlays with display strings, with
> the second overlay "nested" inside the first one:
>
> (defvar myov1 (make-overlay 16 51))
> (overlay-put myov1 'display "STRING1")
> (defvar myov2 (make-overlay 29 43))
> (overlay-put myov2 'display "STRING2")
>
> If you evaluate this in the *scratch* buffer, the result is this:
>
> ;; This buffer STRING1STRING2STRING1, and for Lisp evaluation.
>
> That is, STRING1 is displayed twice! Is this a bug or a feature?
>
> I asked Gerd Möllmann, and he told me that this is an accident: what
> he really meant was, once STRING1 is displayed, to skip to the end of
> its overlay, so that the nested overlay myov2 would not be displayed
> at all.
>
> However, after so many years (this is how Emacs behaves since v21.1),
> perhaps we should keep this behavior. Does anyone know any real-life
> use cases where this "feature" is needed or would be beneficial?
>
> The reason I'm asking is that whether we keep or remove this feature
> affects the detailed design of how bidirectional text should be
> reordered in the presence of display properties and overlay strings.
>
>
>
Hi,
would consider it definitly a bug with respect of
following order of evaluation:
(defvar myov2 (make-overlay 29 43))
(defvar myov1 (make-overlay 16 51))
(overlay-put myov2 'display "STRING2")
(overlay-put myov1 'display "STRING1")
ie if the wider overlay is applied last, it should take all.
Cheers
Andreas
next prev parent reply other threads:[~2011-04-23 19:42 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-04-23 16:44 Nested display strings Eli Zaretskii
2011-04-23 19:42 ` Andreas Röhler [this message]
2011-04-23 20:07 ` Eli Zaretskii
2011-04-23 20:31 ` Drew Adams
2011-04-23 22:16 ` Eli Zaretskii
2011-04-23 23:20 ` Drew Adams
2011-04-24 6:25 ` Eli Zaretskii
2011-04-24 5:01 ` Stefan Monnier
2011-04-24 17:37 ` Eli Zaretskii
2011-04-25 12:47 ` Stefan Monnier
2011-04-25 13:29 ` Eli Zaretskii
2011-04-25 14:57 ` Stefan Monnier
2011-04-25 19:03 ` Juanma Barranquero
2011-04-25 19:41 ` Chong Yidong
2011-04-25 19:56 ` Eli Zaretskii
2011-04-26 18:04 ` Chong Yidong
2011-04-26 18:28 ` Eli Zaretskii
2011-04-26 12:53 ` Stefan Monnier
2011-04-26 17:51 ` Eli Zaretskii
2011-04-26 18:13 ` Ted Zlatanov
2011-04-26 18:25 ` Eli Zaretskii
2011-04-26 18:35 ` chad
2011-04-26 18:50 ` Ted Zlatanov
2011-04-26 19:19 ` Drew Adams
2011-04-28 0:45 ` Stefan Monnier
2011-04-28 16:48 ` Eli Zaretskii
2011-04-28 18:42 ` Stefan Monnier
2011-04-26 20:51 ` Chong Yidong
2011-04-27 0:59 ` Stefan Monnier
2011-04-26 14:46 ` Richard Stallman
2011-04-24 5:19 ` Michael Welsh Duggan
2011-04-24 6:17 ` Eli Zaretskii
2011-04-24 6:22 ` Michael Welsh Duggan
2011-04-24 6:31 ` Andreas Röhler
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4DB32B96.50409@online.de \
--to=andreas.roehler@online.de \
--cc=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.