Colorful bitmap icons in UWP and Uno Platform

The BitmapIcon control makes it simple to add icons in UWP and Uno Platform apps. By default, the icons are monochromatic and adapt to light and dark theme automatically. However, Fluent Design System is now getting more and more colorful so it makes sense to add a splash of color to some iconography in your app as well. It turns out this is very easy to do!

You can use the ShowAsMonochrome property, which by default set to true. Setting it to false disables this behavior and keeps your bitmap colors intact.

For the following simple sample:

We get:

Colorful icon on UWP

And of course the same across all Uno Platform targets! Let’s see WebAssembly for example:

Colorful icon on WASM

If you want to try out this sample on your devices, check out the sample on GitHub!

Buy me a coffeeBuy me a coffee

Leave a Reply

Your email address will not be published. Required fields are marked *

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong>

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.