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

QIcon::isNull() returns false even when QIcon constructed with non-existent file

    XMLWordPrintable

Details

    • Bug
    • Resolution: Invalid
    • P3: Somewhat important
    • Some future release
    • 4.3.1
    • Image formats
    • None

    Description

      The QIcon::isNull() function simply returns whether or not the icon contains a valid d-pointer. This causes problems because if the QIcon constructor (takes a filename) or the addFile() function is called with an invalid filename, then the d-pointer gets initialized anyway even though the file doesn't exist. This differs from the behavior of classes like QPixmap and QImage which will be null if the file does not exist.

      Attachments

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

        Activity

          People

            rodal Samuel Rødal
            jabarron Jason Barron
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes