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

QIcon::fromTheme() does not support all the xdg icon-theme directories nor XPM icons

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P2: Important
    • Some future release
    • 5.1.0 , 5.1.1, 5.2.0
    • GUI: Look'n'Feel
    • None
    • Ubuntu 13.10
    • f6f797a6c3b794d14c312855bacc8b5b89ea6127

    Description

      Icon Theme Specification (http://standards.freedesktop.org/icon-theme-spec/icon-theme-spec-latest.html) states that /usr/share/pixmaps should be one of the default paths to search for icons. Currently QIconLoader does not support loading icons from this directory.

      The spec also says that XPM icons must be supported (although for backwards compability reasons).

      In order to load icons from ~/.icons and /usr/share/pixmaps QIconLoader must also implement a fallback to load icons directly from base dirs (as stated in the spec).

      I've prepared patches to fix these missing functionalities.

      QGenericUnixTheme::xdgIconThemePaths: add /usr/share/pixmaps:
      https://codereview.qt-project.org/63987

      QIconLoader::findIconHelper: also search for XPM images:
      https://codereview.qt-project.org/63988

      QIconLoader::loadIcon: search icons directly from base dirs:
      https://codereview.qt-project.org/63989

      Add QIcon::fromTheme() unit tests:
      https://codereview.qt-project.org/63990

      Attachments

        Issue Links

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

          Activity

            People

              dfaure_kdab David Faure
              wellark Antti Kaijanmäki
              Votes:
              5 Vote for this issue
              Watchers:
              10 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Gerrit Reviews