HI-DPI and SVG icons



  • I am attempting to use Qt 5.6.0's HI-DPI support. I'm using SVGs on my icons. I was hoping that for HI-DPI, the SVGs would scale cleanly. Unfortunately, it appears that the SVGs are rendered to the pixmap first and then the pixmap is scaled to a size appropriate for the HI-DPI screen. This then produces blurry images. Is there some way to force the SVGs rendering to be applied after the output size is specified. Basically, I'd like the pixmap size to change first then the SVG render to occur so that the SVG can be rendered directly and cleanly to the new size.

    Anyone know how to accomplish this (if it's even possible)?



  • if using qml, sourceSize (sourceWidth and sourceHeight) will change svg scale first, then draw it on Image pixmap



  • Thanks for the reply. Unfortunately I'm using QWidgets and not qml.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.