Hi,

On Sat, 30 Aug 2014 18:06:23 -0700,
Unmanifest D <unmanife...@gmail.com> wrote :

> I am building a new application - let's call it A (an X11 app) that
> needs to use an existing X11 application  (that I can't change) -
> let's call it B. I would launch A and occasionally have to to fire up
> B to do some stuff related to what A does/is doing. Ideally, I would
> like B to be a sub-tab or somehow be 'contained within' A - to avoid
> the two showing up as two disconnected applications on the desktop and
> keep the two within the same 'container'. For lack of better options,
> I decided to make Xephyr my container and use i3 to display A and then
> B and switch back-n-forth etc. I'm open to any suggestions on better
> ways of achieving this.

Can't you embed B into A using Xembed?

Here you have an example of a GTK2 window that can embed other
apps (yeah, python2 + gtk2, it's outdated a bit, but you could find out
an equivalent that works with your toolkit):
http://www.moeraki.com/pygtktutorial/pygtk2tutorial/examples/socket.py

If B does not support the Xembed protocol, you can run it inside Xephyr
or Xnest (though this last one did not give good results for me).

Proof of concept:
  $ python2 socket.py
  Socket ID= 35651617
  $ Xephyr :1 -parent 35651617
  $ DISPLAY=:1 xfontsel

Cheers.

Reply via email to