Open Denn1Ro opened 4 years ago
Hi! Is this issue solved? I am having the same problem
I can't recall the workaround that I made but as you can see the issue is still open. So..
If SvgCachedImage
works like CachedImage
, you have to pass a List<ITransformation>
for the Setter.Value
. This works for me:
<ff:CachedImage Source="{Binding ImageUrl}" Aspect="AspectFill" VerticalOptions="FillAndExpand" HeightRequest="120" DownsampleToViewSize="True">
<ff:CachedImage.Triggers>
<DataTrigger Binding="{Binding IsEnabled}" Value="False" TargetType="ff:CachedImage">
<Setter Property="Transformations">
<Setter.Value>
<generic:List x:TypeArguments="work:ITransformation">
<transformations:GrayscaleTransformation />
</generic:List>
</Setter.Value>
</Setter>
</DataTrigger>
</ff:CachedImage.Triggers>
</ff:CachedImage>
Hi, Firstly, thank you for this wonderful package. I use SvgCachedImage and i set the color of the images dynamically. But for some reason doesn't work with triggers. See the code below: `<?xml version="1.0" encoding="utf-8" ?> <ContentPage xmlns="http://xamarin.com/schemas/2014/forms" xmlns:x="http://schemas.microsoft.com/winfx/2009/xaml" xmlns:d="http://xamarin.com/schemas/2014/forms/design" xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" x:Class="DemoFFImageLoading.MainPage" xmlns:ffSvg="clr-namespace:FFImageLoading.Svg.Forms;assembly=FFImageLoading.Svg.Forms" xmlns:ffTransformation="clr-namespace:FFImageLoading.Transformations;assembly=FFImageLoading.Transformations">
` If set the Transformation in code behind it works but with the use of Triggers doesn't. I would like to know if i miss something. Thanks