4

I have two x11 windows which need to maintain a certain stacking order between each other, namely one window needs to stay above the other. I don't care about other windows outside the application. Normally, I would use a parent/child for this, but since X11 clips the child window to the parent, I have to fake it. I've tried various methods to keep and/or adjust the window stack to maintain the proper order. However, the WM is ignoring pretty much everything except for XRaiseWindow() which is too brute force and causes problems for other windows.

So the question is how do I set the stacking between two windows, or is there a way to set a parent/child that doesn't result in the parent clipping the child?

QuickGrip
  • 143
  • 1
  • 8
  • Why can't you use a toolkit like Qt or GTK? Otherwise, read [EWMH](http://standards.freedesktop.org/wm-spec/wm-spec-latest.html) – Basile Starynkevitch Sep 20 '14 at 20:21
  • 1
    Qt GTK are not an option. And yes, I've read EWMH. However, as I said the WM is refusing the commands. – QuickGrip Sep 20 '14 at 21:10
  • 1
    It's controlled by your WM - are you saying you are using a very basic WM, which does not support EWMH? Which WM, which version? Can you use another? For example, the parent-child relation is not a concept of the X11 server, it's something handled in the WM. Just like the parent will not clip the child, but the WM will. So we'd need to know your WM for a start. – Volker Siegel Jun 11 '15 at 16:11
  • 1
    actually clipping parent-child relationship _is_ an X concept. Non-clipping relationship is not, which is what I'm looking for too. Of course both Winows and OSX have basic GUI concepts like that, which is also why they have a market share. –  Jul 04 '15 at 22:58

1 Answers1

2

Yes, you can use the WM_TRANSIENT_FOR Window property to make the (transient) parent appear behind the child without clipping it. Qt uses it internally, you can grep its sources for an example usage.

See also this answer by cap.

fkorsa
  • 684
  • 1
  • 8
  • 22