Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Call for Presentations - Qt World Summit

    Qt Widgets in QML

    QML and Qt Quick
    3
    6
    1803
    Loading More Posts
    • 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
      maxy last edited by

      How to load Qt widgets in QML using Qt Quick 2.0.

      My Qt version is 5.2.1 and Qt Quick 2.0.

      Thanks in Advance

      1 Reply Last reply Reply Quote 0
      • JKSH
        JKSH Moderators last edited by

        Hi,

        What do you mean by "load"?

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

        1 Reply Last reply Reply Quote 0
        • E
          econtech last edited by

          Hi,

          I want to display Qt widget in QML file using Qt Quick 2.0.

          Thanks

          1 Reply Last reply Reply Quote 0
          • JKSH
            JKSH Moderators last edited by

            [quote author="econtech" date="1398747679"]I want to display Qt widget in QML file using Qt Quick 2.0.[/quote]That is not possible, unfortunately. You can put a Qt Quick item inside a widget, but you cannot put a widget inside a Qt Quick item.

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

            1 Reply Last reply Reply Quote 0
            • M
              maxy last edited by

              Hi,

              I want to display Qt Widget in Qml file using Quick 2.0.
              In QtQuick 1.0 there is option QDeclaraticeView is used to load the Widget.

              But I want to display Qt widget in QMl file using QtQuick 2.0. Also I wnat to adjust the size of the widget in Qml file.

              Can you help me.

              Thanks

              1 Reply Last reply Reply Quote 0
              • JKSH
                JKSH Moderators last edited by

                Oh, I see.

                In Qt Quick 2, QDeclarativeView is now called "QQuickView ":http://qt-project.org/doc/qt-5/qquickview.html

                Use the QQuickView to show your QML file. Then, call QWidget::createWindowContainer() to put the QQuickView inside other widgets. (See https://blog.qt.digia.com/blog/2013/02/19/introducing-qwidgetcreatewindowcontainer/ for an example).

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

                1 Reply Last reply Reply Quote 0
                • First post
                  Last post