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

QML BorderImage fails if .sci file contains an url

    XMLWordPrintable

Details

    • 7ddec9f3179bfd854ae53e23ab292de1f9a26377

    Description

      .sci file parsing fails if the source attribute contains an url. This is a big problem especially if you want to use a custom image provider .sci files (currently impossible).

      The precise place of the problem is here (qdeclarativescalegrid.cpp):

      QDeclarativeGridScaledImage::QDeclarativeGridScaledImage(QIODevice *data)
      ...
      QStringList list = line.split(QLatin1Char(':'));
      if (list.count() != 2)
      return;

      --> Will fail if the url contains a colon.

      Here's a solution proposal (replace the above lines with these):

      int colonId = line.indexOf(QLatin1Char(':'));
      if (colonId < 0)
      return;
      QStringList list;
      list.append(line.left(colonId));
      list.append(line.mid(colonId+1));

      Attachments

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

        Activity

          People

            martjone Martin Jones (closed Nokia identity) (Inactive)
            skananoj Sami Kananoja
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes