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

SVG images are blurry

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Duplicate
    • Icon: Not Evaluated Not Evaluated
    • None
    • 5.9.4
    • None
    • Mac OS High Sierra
      Windows 10

      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. 

        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
            davidbirkas David Birkas
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                There are no open Gerrit changes