[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
png images in tool-bar / alpha mask
From: |
David Reitter |
Subject: |
png images in tool-bar / alpha mask |
Date: |
Tue, 1 Apr 2008 18:14:45 +0100 |
I'm trying to use PNG images with alpha information in the tool-bar
and find that the mask / alpha is ignored:
(find-image (list (list :type 'png :file "undo.png")))
i.e. I'm not setting a ":mask 'heuristic" property here. The
background just appears white.
This is with the new toolkit toolbars (under Carbon), but I remember
having such problems with the non-toolkit toolbar as well.
`image-make-p' generally returns nil for PNGs.
It seems that "image_load_quartz2d" is used to load the file (in
image.c). This already determines some background colors and draws it
into a new graphics context, with the background color present. And
then it doesn't actually store the original image data, but creates an
XCreatePixmap. (A mask is handled separately.)
Would the solution be to also store the original image data
(CGImageRef) in the "struct image", and then to simply use that when
defining the toolbar, if it is present and if the toolkit supports it?
As is probably obvious, I'm not familiar with how this is generally
handled in Emacs, but if someone could provide a bit of guidance, I
could try to make it work.
- png images in tool-bar / alpha mask,
David Reitter <=
- Re: png images in tool-bar / alpha mask, YAMAMOTO Mitsuharu, 2008/04/02
- Re: png images in tool-bar / alpha mask, David Reitter, 2008/04/01
- Re: png images in tool-bar / alpha mask, YAMAMOTO Mitsuharu, 2008/04/02
- Re: png images in tool-bar / alpha mask, David Reitter, 2008/04/03
- Re: png images in tool-bar / alpha mask, YAMAMOTO Mitsuharu, 2008/04/03
- Re: png images in tool-bar / alpha mask, David Reitter, 2008/04/03
- Re: png images in tool-bar / alpha mask, YAMAMOTO Mitsuharu, 2008/04/03
- Re: png images in tool-bar / alpha mask, David Reitter, 2008/04/03
- Re: png images in tool-bar / alpha mask, YAMAMOTO Mitsuharu, 2008/04/03
- Re: png images in tool-bar / alpha mask, David Reitter, 2008/04/04