xclock use this extension to have non-rectangular windows, low priority feature request to support it.
Looks like we should select for shape events with
XShapeSelectInput and call
XShapeGetRectangles to get the list of rectangles for a window, then we can pass that to the client...
work in progress patch: send shape as metadata to X11 clients
The patch above does most of what we need, except:
We probably want this in a reasonable shape (pun intended) before closing #885.
Mostly done in r9657, this will do for now. xeyes works!
Remaining items (which may well get re-scheduled):
XShapeCombineRectangles, maybe from the "extents" values? (until an app uses it, I'm not sure)
shows off VirtualBox?'s seamless mode running within Xpra: IE8 and control panel directly on the Linux desktop
example xshape code
cairo xshape example
Found some examples to use for testing (beyond xeyes and virtualbox):
The source is now attached to this ticket in case googlecode loses yet more code.
The first one shows that the implementation is missing something: the window ends up not being transparent... The second one works fine.
I have moved the osx and win32 items to #893.
python gtk example
Well, well. Turns out this is a bit of a monster of a bug, and not in the xshape code at all: r9671 fixes xshape for OR windows in trunk, as well as a long list of other properties we were failing to propagate for OR windows: "title", "size-hints", "fullscreen", "fullscreen-monitors", "bypass-compositor", "maximized", "opacity", "workspace", "strut", "shape".
This should be backported to all supported branches, but I think I'll just wait for the next point release to make sure this does not have undesirable side effects.
Apart from that, this is ready for testing, just connect with a Linux client and fire up one of the test applications:
gcc $(pkg-config xext x11 cairo-xlib-xrender --cflags --libs) cairo-xshape-example.c -o cairo-xshape-example ./cairo-xshape-example
gcc $(pkg-config xext x11 --cflags --libs) xshape.c -o xshape ./xshape
@afarr: mostly a FYI, feel free to close as an acknowledgement.
Started a r9688 Fedora 21 Trunk Server:
shapedwindow.pyworks as expected when connecting from Fedora 20 Trunk r9688
Consulted with Alex, and this has been acknowledged. Closing!
Problem is that the scaling code added in r10652 is too slow, so r12781 defaults to the lazy direct scaling of rectangles - will backport. This fixes latest versions of google-chrome which seem to reset the xshape values far too often, causing multi-second stalls.
r14363 makes it possible to disable the xshape code with the
XPRA_SHAPE=0 env var.
this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/501