Results 1 to 6 of 6

Thread: QX11EmbedContainer into a QSplitter (qt 4.4.3)

  1. #1

    Default QX11EmbedContainer into a QSplitter (qt 4.4.3)

    I have to put an xterm into a QSplitter but when i call embedClient()... At the moment I can get the xterm outside the splitter.

    Qt Code:
    1. QString ID = "0x3a0000e"; // I've taken this id from xwininfo -root -all | grep xterm
    2. bool* x = new bool(true);
    3. container->embedClient(ID.toInt(x,16));
    To copy to clipboard, switch view to plain text mode 

    With this code I get the outside xterm.

    How can I use a QProcess and embed it in the container?
    And specially, how can I know its winId from qt? (without using xwininfo)
    Last edited by jpn; 23rd December 2008 at 21:47. Reason: missing [code] tags

  2. #2
    Join Date
    Dec 2006
    Posts
    849
    Thanks
    6
    Thanked 163 Times in 151 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QX11EmbedContainer into a QSplitter (qt 4.4.3)

    You can not, as far as I know.
    (You sometimes can do hacks like telling the called program what window title it should display. Then you can query X11... basically search for the Window with that title. I did that once. You have to take care, though, to wait a bit til the window does exist.)

    Tell us if you find a better way.

    HTH

  3. #3

    Default Re: QX11EmbedContainer into a QSplitter (qt 4.4.3)

    My problem is that I need a terminal in my app.
    I've been trying with konsolepart,and starting a program within it, but I wasn't able to know when the program was finished
    Suggestions?

  4. #4
    Join Date
    Dec 2006
    Posts
    849
    Thanks
    6
    Thanked 163 Times in 151 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QX11EmbedContainer into a QSplitter (qt 4.4.3)

    Usually these terminal programs have an option to set the X window title. Check the man page for details.
    (One of the apps I embedded by searching for the window with 'my' title was an rxvt terminal program.)

  5. #5

    Smile Re: QX11EmbedContainer into a QSplitter (qt 4.4.3)

    and the source code of your app is available? tnx

  6. #6
    Join Date
    Dec 2006
    Posts
    849
    Thanks
    6
    Thanked 163 Times in 151 Posts
    Qt products
    Qt4
    Platforms
    Unix/X11

    Default Re: QX11EmbedContainer into a QSplitter (qt 4.4.3)

    Sorry, I am not allowed to post that.
    (hint: XQueryTree and XWindowName)

    HTH

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.