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

REG: Qt 6.9.1 -> 6.9.2: QFileDialog (non-native) is missing some icons for directories

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Not Evaluated Not Evaluated
    • None
    • 6.9.2
    • None
    • Windows 10/11
    • Windows

      When running the code below for Qt 6.9.2 under Windows 10/11, the non-native file dialog fails to show the icons for some of the directories it lists. On the two systems I tested, it did not show icon for the "C:/Users" directory and others.

      When running this code compiled for Qt 6.9.1, the file dialogs do show all the directory icons.

      Code below is also attached.

       

      #include <QString>
      #include <QFileDialog>

      #include <QApplication>

      int main(int argc, char *argv[])

      { // initial directory   static const QString dir

      { QStringLiteral("C:/") }

      ;

        QApplication app(argc,argv);

        // non-native file dialog at root of system drive
        QFileDialog filedialog(nullptr,"test",dir);
        filedialog.setOption(QFileDialog::DontUseNativeDialog);
        filedialog.setViewMode(QFileDialog::Detail);

        // note that the "Users" directory does not have an icon (unlike the other ones).
        // also within the "Users" directory, the directory for the current user also
        // does not have an icon.
        // besides these directories, there are more directories missing their icon
        // (also on other drives). it seems to only affect directories, not drives/files.
        filedialog.show();

        return QApplication::exec();
      }

        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
            ev E Visser
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:

                There are no open Gerrit changes