Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. Display a Java UI application in a QWidget frame
Qt 6.11 is out! See what's new in the release blog

Display a Java UI application in a QWidget frame

Scheduled Pinned Locked Moved Unsolved General and Desktop
4 Posts 2 Posters 1.7k Views 2 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • G Offline
    G Offline
    giesbert
    wrote on last edited by
    #1

    Hi,
    I'm working in a bigger project in the area of electrical network control centers. We have a huge hybrid application with different programming languages (C, C++, Qt, Java, Fortran, ...).
    Our Main UI is Qt and Web Page based (displayed in Qt). Now we have to integrate a Java Based UI somehow and it should be displayed in a QWidget frame.
    Is it possible to bring a Java Based application to render in a Qt Widget somehow? I know, long time ago, ther was QtJambi, but that seems to be dead and is still for Qt 4.X and the wrong way round.

    Regards

    Giesbert

    Nokia Certified Qt Specialist.
    Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by
      #2

      hi
      You might be able to grab it with

      HWND hwnd = FindWindowEx(...) // find the java window
      QWidget *widget =Widget::createWindowContainer(QWindow::fromWinId((WId)hwnd));

      to wrap it into a widget but Im not sure about what happens to the events.

      This is purely speculation. though.

      1 Reply Last reply
      1
      • G Offline
        G Offline
        giesbert
        wrote on last edited by
        #3

        Hi,

        Yeah that would eventually work on windows, we have to try it. I completly forgot this feature on windows, shame on me....
        Thanks a lot, we will give it a try...

        Nokia Certified Qt Specialist.
        Programming Is Like Sex: One mistake and you have to support it for the rest of your life. (Michael Sinz)

        1 Reply Last reply
        1
        • mrjjM Offline
          mrjjM Offline
          mrjj
          Lifetime Qt Champion
          wrote on last edited by
          #4

          Sadly , I know of no cross platform way to try it :(

          1 Reply Last reply
          1

          • Login

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Users
          • Groups
          • Search
          • Get Qt Extensions
          • Unsolved