Instruction set reference
HIPE_OP_GET_X11_XID
Turns an object element into a place where the window of an X11 application can be embedded. The display server creates an X11 window at the element's position and keeps it at the element's position and size from then on. It replies with HIPE_OP_X11_XID_RETURN, which carries the window's XID.
- location: the object element to embed into.
- No arguments.
Notes
The client does the embedding itself: once it has the XID, it reparents the other application's window into it over its own connection to the X server (for example with XReparentWindow).
The embedded window is a real X11 window and is drawn above everything in the Hipe frame, so nothing in the document can be placed over it. To hide it for a while (for example, to show a menu or a dialog where it is), give the object element the style visibility: hidden. The window reappears when the element is made visible again.
Don't hide it with display: none. That destroys the X11 window, and the application's window embedded in it is destroyed too. Making the element visible again creates a new, empty window with a new XID.
The reply's XID is 0, and nothing is created, if:
- the element isn't an object element; or
- hiped isn't itself running on X11. Where both X11 and Wayland are available, Qt may choose Wayland; start the display server with QT_QPA_PLATFORM=xcb hiped to make it use X11.
