GNU bug report logs - #77104
31.0.50; Transparent png image background is ignored in frames with alpha-background

Previous Next

Package: emacs;

Reported by: Ihor Radchenko <yantar92 <at> posteo.net>

Date: Tue, 18 Mar 2025 18:05:02 UTC

Severity: normal

Found in version 31.0.50

Full log


View this message in rfc822 format

From: Eli Zaretskii <eliz <at> gnu.org>
To: Ihor Radchenko <yantar92 <at> posteo.net>, Po Lu <luangruo <at> yahoo.com>, Alan Third <alan <at> idiocy.org>
Cc: dybfysiat <at> 163.com, 77104 <at> debbugs.gnu.org
Subject: bug#77104: 31.0.50; Transparent png image background is ignored in frames with alpha-background
Date: Wed, 19 Mar 2025 14:14:28 +0200
> Cc: gynamics <dybfysiat <at> 163.com>
> From: Ihor Radchenko <yantar92 <at> posteo.net>
> Date: Tue, 18 Mar 2025 18:03:23 +0000
> 
> Try the following starting from emacs -Q + the attached .png file:
> 
> 1.
> 
> (let ((ov (make-overlay 1 10)))
>   (set-frame-parameter nil 'alpha-background 90)
>   (overlay-put
>    ov
>    'display
>    (create-image
>     "/path/to/image.png"
>     nil nil :width 100)))
> 
> 2. Observe image background not being transparent, but instead using
> default face background.
> 
> 3.
> 
> (let ((ov (make-overlay 1 10)))
>   (set-frame-parameter nil 'alpha-background 90)
>   (overlay-put
>    ov
>    'display
>    (create-image
>     "/path/to/image.png"
>     nil nil :width 100 :mask 'heuristic)))
> 
> 4. With :mask 'heuristic, the background becomes transparent (mod
> "rough" edges due to clipping)
> 
> I believe that (1) is a bug.
> 
> See also https://list.orgmode.org/orgmode/7324dc0.f8517.195a224ffd1.Coremail.dybfysiat <at> 163.com/

Po Lu and Alan, is this a bug or a missing feature?




This bug report was last modified 87 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.