Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. How do the "QML" and "QMLScene" tools differ?
QtWS25 Last Chance

How do the "QML" and "QMLScene" tools differ?

Scheduled Pinned Locked Moved Solved QML and Qt Quick
2 Posts 1 Posters 66 Views
  • 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.
  • R Offline
    R Offline
    RokeJulianLockhart
    wrote 21 days ago last edited by RokeJulianLockhart
    #1

    In ≥ Qt 5, qmlscene and qml appear to exist simultaneously with official support for the identical purpose of prototyping GUIs, yet purportedly differ. How do they differ?

    When using a forum, remember to tag the person you are responding to, in case they are not subscribed to the thread.

    R 1 Reply Last reply 21 days ago
    0
    • R RokeJulianLockhart
      21 days ago

      In ≥ Qt 5, qmlscene and qml appear to exist simultaneously with official support for the identical purpose of prototyping GUIs, yet purportedly differ. How do they differ?

      R Offline
      R Offline
      RokeJulianLockhart
      wrote 21 days ago last edited by RokeJulianLockhart
      #2

      @RokeJulianLockhart, interest.qt-project.narkive.com/p4tyYKC9 states:

      The QML tool is a bit more flexible, makes fewer assumptions (e.g. it doesn’t use a QApplication by default, so you don’t end up loading the widgets module into memory if you don’t need it) and is meant as the long-term replacement for qmlscene.

      QML can be used for non-graphical purposes if your root object is a plain QObject, not an Item or Window; that’s only practical with the qml tool, not qmlscene. It is more directly analogous to other language interpreters like python and perl (which also do not load graphical libraries unless you import the relevant modules in your script), and you can even use the shebang mechanism, so that qml files can be marked executable and run from the command line.

      You can configure your window system to use it as the default application with which to run any file with the qml extension (e.g. when double-clicking a qml file in your file manager/finder), if you like. (QTBUG-33659 is a request to set up that association when you install the SDK, but that never got done AFAIK. It requires someone with Qt Installer expertise, I think.)

      So you could nearly forget about qmlscene, except that it has a few handy command-line options that qml still doesn’t.

      When using a forum, remember to tag the person you are responding to, in case they are not subscribed to the thread.

      1 Reply Last reply
      1
      • R RokeJulianLockhart has marked this topic as solved 21 days ago

      1/2

      19 Apr 2025, 09:06

      • Login

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