Open orcuns opened 1 year ago
Hey @orcuns , sorry for the late response. Here's how to use it with Jetpack Compose:
@Composable
fun VectorPathFinderIV(){
AndroidView(factory = {context ->
val iv = ImageView(context)
val vector = VectorChildFinder(context, R.drawable.baseline_add_chart_24,
iv)
val path1 : VectorDrawableCompat.VFullPath = vector.findPathByName("mypath1")
path1.fillColor = Color.YELLOW
iv
}, update = {
it.invalidate()
})
}
Then call VectorPathFinderIV()
to show the image.
I can't make it with Jetpack compose unfortunately. Maybe someone else knows a way to make it work?