[Top][All Lists]

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

Unexpected hiding of identical images

From: Kim F. Storm
Subject: Unexpected hiding of identical images
Date: Mon, 18 Jul 2005 16:04:27 +0200 (CEST)

Try to eval this with latest CVS (emacs started from src directory):

 (auto-image-file-mode 1)
 (find-file "../etc/gnu.xpm")
 (let ((i (buffer-substring (point-min) (point-max)))
       (inhibit-read-only t))
   (switch-to-buffer (get-buffer-create "*test*"))
   (insert i)
   (insert i)
   (insert i)))

Now, in the test buffer, I clearly inserted 3 copies of the image, but
only one image is visible.

I discovered this when I copied the gnu image with the mouse and then
tried to paste it into a buffer more than once -- and I got very
confused to only see one image, no matter how many times I pasted it...

Problem is between redisplay and intervals:

when pos is on first image, redisplay calls the following:
     -> Fnext_single_char_property_change
        -> Fnext_char_property_change
           -> Fnext_property_change
              -> intervals_equal

And since the property list of the three images are fully identical
(the same cons cell), the second and third images (intervals) which
are adjacent to the first image (interval), are skipped by

I understand why the interval code does this for ordinary text
properties, but it obviously breaks for the display property.

I tried to change intervals_equal to never consider two intervals with
display properties to be equal, but that didn't do the trick.

Any ideas how to fix this?

In GNU Emacs (i686-pc-linux-gnu, X toolkit, Xaw3d scroll bars)
 of 2005-07-18 on kfs-l.imdomain.dk
X server distributor `The XFree86 Project, Inc', version 11.0.40300000
Important settings:
  value of $LC_ALL: nil
  value of $LC_COLLATE: nil
  value of $LC_CTYPE: nil
  value of $LC_MESSAGES: nil
  value of $LC_MONETARY: nil
  value of $LC_NUMERIC: nil
  value of $LC_TIME: nil
  value of $LANG: en_US.UTF-8
  locale-coding-system: utf-8
  default-enable-multibyte-characters: t

Kim F. Storm <address@hidden> http://www.cua.dk

reply via email to

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