Home Overwriting the "template" of an Image?
Reply: 0

Overwriting the "template" of an Image?

user1028 Published in March 18, 2018, 1:49 am

step by step I try to implement themes into my application. This includes a nightmode, where the background is dark and the foreground white. Formerly I had plain black icons which cannot be seen anymore when the background is dark as well so I need to make them change colors on demand.

I achieved doing this by using a rectangle with an OpacityMask

    Fill="{DynamicResource BlackBrush}">
        <ImageBrush ImageSource="{Binding MyStatus}" Stretch="Uniform"/>

This is a viable solution but it's very time consuming to go through the whole application to change all the images. So my question is. Is there any way to make a change (style or something like that) to replace all images with such a rectangle? Is there a contentTemplate for image I could replace?

You need to login account before you can post.

About| Privacy statement| Terms of Service| Advertising| Contact us| Help| Sitemap|
Processed in 0.31737 second(s) , Gzip On .

© 2016 Powered by mzan.com design MATCHINFO