Commit df30bdb3 authored by JP Dinger's avatar JP Dinger

Skins2: Add x11 transparency support. Hope it sets the property on the right...

Skins2: Add x11 transparency support. Hope it sets the property on the right Window; didn't have a known transparent skin to test with.
parent 77aa98d0
......@@ -185,7 +185,16 @@ void X11Window::raise() const
void X11Window::setOpacity( uint8_t value ) const
{
// Sorry, the opacity cannot be changed :)
Atom opaq = XInternAtom(XDISPLAY, "_NET_WM_WINDOW_OPACITY", False);
if( 255==value )
XDeleteProperty(XDISPLAY, m_wnd, opaq);
else
{
uint32_t opacity = value * ((uint32_t)-1/255);
XChangeProperty(XDISPLAY, m_wnd, opaq, XA_CARDINAL, 32,
PropModeReplace, (unsigned char *) &opacity, 1L);
}
XSync( XDISPLAY, False );
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment