Results 1 to 6 of 6

Thread: Qt5 does not have X11 API, how to port from Qt4 to Qt5?

  1. #1
    Join Date
    Mar 2013
    Location
    Hyderabad,Bangalore,India
    Posts
    70
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    8
    Thanked 4 Times in 4 Posts

    Default Re: Qt5 does not have X11 API, how to port from Qt4 to Qt5?

    Hi,
    I need to port some applications from Qt4.8 to Qt5.0.
    In Qt4.8 all the applications i used QX11EmbedXXX functions, but Qt5.0 does not have the support for X11.

    is there any other way we can embed widgets in Qt5.0.
    Is it possible using OpenGL or QGraphicsView related functions, if so kindly provide any reference or example.


    Thanks,


    Added after 1 9 minutes:


    I Actually need Qt5.0.1.
    Where can i find all the functions and modules available in Qt5.0.1.
    Last edited by PstdEr; 9th October 2013 at 11:36.

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts

    Default Re: Qt5 does not have X11 API, how to port from Qt4 to Qt5?

    QX11Embed sounds like you are looking at XEmbed functionality.

    QWindow::fromWinId() can do that now, in a cross-platform way.

    Cheers,
    _

  3. #3
    Join Date
    Mar 2013
    Location
    Hyderabad,Bangalore,India
    Posts
    70
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    8
    Thanked 4 Times in 4 Posts

    Default Re: Qt5 does not have X11 API, how to port from Qt4 to Qt5?

    yeah , got to see recently.

    But i have doubt here.

    in Qt 4 QX11EmbedContainer can give its window id so that other applications can be embedded into it.

    for non Qt application i used to pass window id through command line and get those application embedded into my window

    in Qt 5 createWindowContainer needs a window id so that it can embed that application.
    for non Qt applications how can get the window id of a running application and send it to container so that it will embed into it.

  4. #4
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts

    Default Re: Qt5 does not have X11 API, how to port from Qt4 to Qt5?

    These are two different usage scenarios.

    QWindow::fromWinId() solves the on where you have a foreign window and embed it into your application. Ideally the foreign window communicates the window id to your application somehow, or makes it window identifiable through certain window attributes and you search for those through use of native API or, if the platform QPA has support for that, through those support features.

    The other way around, when your application provides a window id and the foreign window embeds itself somehow, might be supported by creating an otherwise empty QWindow and passing its winId() to the other application.

    Cheers,
    _

  5. #5
    Join Date
    Mar 2013
    Location
    Hyderabad,Bangalore,India
    Posts
    70
    Qt products
    Qt4
    Platforms
    Unix/X11
    Thanks
    8
    Thanked 4 Times in 4 Posts

    Default Re: Qt5 does not have X11 API, how to port from Qt4 to Qt5?

    Hi anda_skoa,

    How will I find out , is there any way to embed widgets in Qt 5.0.1?
    you mentioned earlier about QWindow::fromWinId() , createWindowContainer , but they are available in Qt 5.1.


    Thanks,

  6. #6
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts

    Default Re: Qt5 does not have X11 API, how to port from Qt4 to Qt5?

    You can probably use the same native API that the XCB QPA in Qt5.1 is using.

    Cheers,
    _

Similar Threads

  1. COM-port in Qt
    By Victor007 in forum Qt Programming
    Replies: 11
    Last Post: 29th July 2013, 10:43
  2. how to port from qt3 to qt4
    By narlapavan in forum Qt Tools
    Replies: 3
    Last Post: 5th July 2013, 06:34
  3. how to port from qt3 to qt4
    By narlapavan in forum Qt Programming
    Replies: 1
    Last Post: 21st June 2013, 09:17
  4. Replies: 1
    Last Post: 13th March 2013, 09:44

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
  •  
Qt is a trademark of The Qt Company.