Change svg image colors at runtime? #163
Replies: 6 comments 8 replies
-
@swaroopsomanna I have looked into ways to support themes, but gave up! There is no standard way to handle it, so instead I provided several means to implement it. |
Beta Was this translation helpful? Give feedback.
-
No style ID or classes is used. I just want all white colors to become black. That's all. |
Beta Was this translation helpful? Give feedback.
-
@swaroopsomanna Sorry for the late response, please can you provide a sample SVG file for illustration? |
Beta Was this translation helpful? Give feedback.
-
That's ok |
Beta Was this translation helpful? Give feedback.
-
Now I'm using monochrome icons with blue foreground that works best for both black and white themes. Thanks anyway. |
Beta Was this translation helpful? Give feedback.
-
So how to change foreground at runtime??? |
Beta Was this translation helpful? Give feedback.
-
Alright, so I have a bunch of svg images that I've added to my application as resources. I'm using these images as a icons for several buttons by adding these images to svg viewport within the buttons. These images are multicolored and a part of it contains white color. Now what I want to achieve is during my application's runtime when I change the application theme (which I can handle) I want the white parts of the svg images in the buttons to become black. Is this possible with sharp vectors? If yes, how?
Beta Was this translation helpful? Give feedback.
All reactions