Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-74252

empty icons on QQC2 and Qt 5.12

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Done
    • Icon: P2: Important P2: Important
    • 5.12.9, 5.15.1
    • 5.12.0
    • Quick: Controls 2
    • None
    • Linux/X11
    • add92a551cf601b5c9e074046326f95ccc38062e (qt/qtbase/dev) 47fed5b00732902d57063902c98d0a601d9ff239 (qt/qtbase/5.12) 843a3b4bf1fd62a72646afaf0efb348b1f444b78 (qt/qtbase/5.15)

      on Linux, for most styles (for instance Material is affected) the following code, doesn't show an icon anymore (worked fine in Qt 5.10 and 5.11):

      Button

      {     icon.name: "go-up" }

       

      looking into QQuickIconImage::setName(), it loads the icon with

      d->icon = QIconLoader::instance()->loadIcon(name);

      if i do:

      qDebug()<<QIconLoader::instance()->themeName(); i can see it has an empty theme name, instead of the system one.

      If i add before loadIcon() the code:

      QIconLoader::instance()->updateSystemTheme();

      it sets the correct theme and the icon is loaded correctly.

       

      updateSystemTheme doesn't seem to be called anywhere in either qtbase or qtquickcontrols2 repositories, where should this be done?

       

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

            qt.team.quick.subscriptions Qt Quick and Widgets Team
            notmart Marco Martin
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: