回复: transparent background of XLib window
LIDE
1053481745 at qq.com
Sun Apr 13 19:18:03 PDT 2014
Hi:
I don't know if you understand my requirement.I want a subregion of the window transparent.That is to say, I use XClearArea to make an area show the background of the window.I want to set the background of the window transparent.So, I can get a subregion that is transparent.I want to use this region to show the content under the window.Xshape is not suit for me.because the events of that region I still want to use.
------------------ 原始邮件 ------------------
发件人: "Thomas Lübkin";<thomas.luebking at gmail.com>;
发送时间: 2014年4月13日(星期天) 晚上7:42
收件人: "LIDE"<1053481745 at qq.com>;
抄送: "xorg"<xorg at freedesktop.org>;
主题: Re: transparent background of XLib window
On Freitag, 11. April 2014 12:16:48 CEST, LIDE wrote:
> Dear:
> I want to create a window that has a transparent
> window.But I really don't know how to achieve.I just set the
> window depth 32,what should I do next?
> Sorry to my poor English.Waiting for your replay.THANKS!
In case you want a *transparent* (invisible) window, pass InputOnly as "class" parameter to XCreateWindow
http://tronche.com/gui/x/xlib/window/XCreateWindow.html
If you want a *translucent* (partially transparent/translucent content) window you require a running compositor (to see the translucency)
You'll also have to provide correct visual and colormap, see eg. here:
http://stackoverflow.com/questions/3645632/how-to-create-a-window-with-a-bit-depth-of-32
Cheers,
Thomas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg/attachments/20140414/0eb4b972/attachment.html>
More information about the xorg
mailing list