Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 77050

Image Opacity Mask to apply color to image possible in Xamarin.Forms?

$
0
0

In WP8.0, you can do this

<Rectangle
Width="24"
Height="24"
Fill="#F00">
    <Rectangle.OpacityMask>
        <ImageBrush
            Stretch="Fill"
            ImageSource="LikeIcon.png" />
    </Rectangle.OpacityMask>
</Rectangle>

And in WP8.1:

<BitmapIcon
    Height="24"
    Width="24"
    Foreground="#F00"
    UriSource="LikeIcon.png" />

To turn this into this


Is it possible to color images in this fashion with Xamarin.Forms?

(#F00 is just a sample, clearly the second image is not red)


Viewing all articles
Browse latest Browse all 77050

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>