GNU bug report logs -
#39736
27.0.60; wrong display of scaled checkerd pattern image
Previous Next
Reported by: ynyaaa <at> gmail.com
Date: Sat, 22 Feb 2020 14:28:01 UTC
Severity: normal
Merged with 38394
Found in version 27.0.60
Done: Alan Third <alan <at> idiocy.org>
Bug is archived. No further changes may be made.
Full log
Message #19 received at 39736 <at> debbugs.gnu.org (full text, mbox):
[Message part 1 (text/plain, inline)]
Eli Zaretskii <eliz <at> gnu.org> writes:
>> > The form below temporally displays another image.
>> > The upper side is gray, the lower-left corner is black,
>> > and the lower-right corner is white.
>> > Once the text cursor gets on the image, the whole image is displayed as
>> > a gray square.
>> >
>> > (let ((data "P1\n2 2\n01\n10")
>> > (buf (generate-new-buffer "tmp")))
>> > (switch-to-buffer buf)
>> > (insert "\na")
>> > (goto-char (point-min))
>> > (redisplay)
>> > (insert-image (create-image data 'pbm t :scale 16)))
>>
>> I tried this and couldn’t replicate it, but I believe I had the patch
>> for 38394 applied, so it may be a fix. Alternatively it could be
>> related to the way the cursor is drawn on images.
>
> I didn't see any temporary display, either, FWIW.
I tested with various :scale values.
(let* ((data "P1\n2 2\n01\n10")
(buf (generate-new-buffer "tmp"))
(max (1+ (frame-char-height)))
(scale 4))
(switch-to-buffer buf)
(while (<= scale max)
(erase-buffer)
(insert (format "\nscale: %g" scale))
(goto-char (point-min))
(redisplay)
(insert-image (create-image data 'pbm t :scale scale))
(insert ?_)
(sit-for 0.5)
(setq scale (1+ scale))))
It seems that if the image is partially displayed under '_',
lower area is painted black and white.
And the maximum value which causes temporary display seems to be
(frame-char-height).
For example, just started after emacs -Q, (frame-char-height) is 16
and :scale 17 simply displays solid gray square.
After (set-frame-font "Courier New-18"), (frame-char-height) is 27
and :scale 28 simply displays solid gray square.
The attached image shows how the square image id displayed.
[emacs-tmp2.png (image/png, attachment)]
This bug report was last modified 4 years and 342 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.