luberda-molinet / FFImageLoading

Image loading, caching & transforming library for Xamarin and Windows
MIT License
1.42k stars 377 forks source link

How can I use SVG icons for Tabbed pages? #1416

Open Schenky opened 4 years ago

Schenky commented 4 years ago

Hi,

I' trying to use FFImageLoader to display SVG icons on tabbed pages: If I use a PNG image, it's working fine. `

But when I try with an SVG image, I get an XAML design time error.

` Error: Property 'IconImageSource' does not support values of type 'SvgCachedImage'. I also tried adding from code (in the ContentPage xaml.cs file) . No error, but still not working. `IconImageSource = new FFImageLoading.Svg.Forms.SvgImageSource("folder_24px.svg", 20, 20, true);` What am I doing wrong? How should I do it? I'm using Xamarin Forms 4.4.0.991640 anf FFImageLoading 2.4.11.982
artur309 commented 4 years ago

i normally use the png format, xamarin can fill up the color when selected

Schenky commented 4 years ago

I'm trying to avoid to upload the images in multiple resolutions, and also I need the same icon in several other places (where svg image display works), so it would be ideal to have a single scalable resource. Is it considered eventually in future developements?

galactose310 commented 4 years ago

Same problem and same needs for me. If someone has a solution...

artur309 commented 4 years ago

Same problem and same needs for me. If someone has a solution...

I tried use the svg to but i converted all my svg to png and it worked. Even the lines of icons are highlited with the selected color.

I didnt use the FFImageLoading

superbeller commented 4 years ago

Somebody knows how solve this problem???

artur309 commented 4 years ago

Somebody knows how solve this problem???

Its seems no

EmilAlipiev commented 4 years ago

it is not possible till today but this is i believe more related to xamarin.forms team.

artur309 commented 4 years ago

it is not possible till today but this is i believe more related to xamarin.forms team.

i didn't use the FF i simply convert SVG TO PNG and it worked, and i have was possible to change the line colors

Edgaras91 commented 3 years ago

Any update on this? Anyone got it working?

artur309 commented 3 years ago

damn is still a issue? :/

winkmichael commented 3 years ago

I know it's been a while, did anyone ever figure this out? Trying to use SVG in Xamarin Flyouts.