How ribbon icons stay sharp on scaled display?

Ribbon for WPF Forum

Posted 4 months ago by rex hui
Version: 22.1.2
Avatar

When the Windows display scale setting is changed to something other than 100%, the icons on the ribbon bar become blurry.

Microsoft office applications do not have this problem. Their icons stay sharp.

How do they manage to do that?

Comments (2)

Answer - Posted 4 months ago by Actipro Software Support - Cleveland, OH, USA
Avatar

Hello,

For icons to remain sharp when in scaled-up DPIs, you must use vector icons (.svg, etc.) instead of raster icons (.png, .jpg, etc.).  In WPF, vector icons are best served using the WPF DrawingImage class.

Since Microsoft has not included a SVG-based ImageSource class natively, this open-source tool (https://github.com/BerndK/SvgToXaml) is an amazing helper for converting .svg files to WPF DrawingImages.  Then you can use those DrawingImages in your app and they will be crisp at any DPI.


Actipro Software Support

Posted 4 months ago by rex hui
Avatar

Thank you very much!

The latest build of this product (v22.1.4) was released 19 days ago, which was after the last post in this thread.

Add Comment

Please log in to a validated account to post comments.