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

SVG images are blurry

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Not Evaluated
    • Resolution: Duplicate
    • Affects Version/s: 5.9.4
    • Fix Version/s: None
    • Labels:
      None
    • Environment:
      Mac OS High Sierra
      Windows 10

      Description

      SVG images are blurry since Qt 5.6 and are still blurry in Qt 5.9.4.

      SVGs are an essential part of desktop applications how come they have so low priority and still not getting fixed?

      To fix the issue I have to use this workaround:

      QtQuick.Item {
          id: _baseSVGImage
      
          property alias svgImage: _svgImage
      
          property real margins: 0
      
          QtQuick.Image {
              id: _svgImage
      
              anchors {
                  fill: parent
                  margins: _baseSVGImage.margins
              }
      
              sourceSize.height: height * QtQuick_Window.Screen.devicePixelRatio
              sourceSize.width: width * QtQuick_Window.Screen.devicePixelRatio
      
              fillMode: QtQuick.Image.PreserveAspectFit
          }
      }
      

      But for this workaround I must set a width and height so it works, which is pretty annoying. 

        Attachments

          Issue Links

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

            Activity

              People

              Assignee:
              qt.team.quick.subscriptions Qt Quick and Widgets Team
              Reporter:
              davidbirkas David Birkas
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Gerrit Reviews

                  There are no open Gerrit changes