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. Problems occurred while tying to use createWindowContainer()
Qt 6.11 is out! See what's new in the release blog

Problems occurred while tying to use createWindowContainer()

Scheduled Pinned Locked Moved Unsolved General and Desktop
3 Posts 3 Posters 1.2k 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.
  • M Offline
    M Offline
    MV9618
    wrote on last edited by
    #1

    Hello,

    I'm developing an application on Windows and I'm having some problems when trying to include an external window in Qt.
    I read various posts on this topic but I'm still unable to fix the problem:

    I have the following snippet of code:

    QWindow appWin = QWindow::fromWinId(winid);
    QWidget appWidget = QWidget::createWindowContainer(appWin);
    

    it actually creates the required widget which displays what I need it to display. The problem is that I'm getting a white border(inside the widget) which surrounds the view.

    Could anybody help me?

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

      Hi and welcome to devnet,

      You should add:

      • Version of Qt
      • OS version
      • What you are embedding in that widget

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • JKSHJ Offline
        JKSHJ Offline
        JKSH
        Moderators
        wrote on last edited by
        #3

        Be aware that embedding external windows in widgets are problematic: https://bugreports.qt.io/browse/QTBUG-40320

        I believe Qt 6 is meant to have improved support for embedding windows, but I haven't tested it myself yet. Perhaps you can download the Qt 6.0.0 beta and try it?

        Qt Doc Search for browsers: forum.qt.io/topic/35616/web-browser-extension-for-improved-doc-searches

        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