https://kotlinlang.org logo
c

Colton Idle

02/24/2021, 10:14 PM
Okay. I feel stupid. An Icon takes an ImageVector. I used to just use an Image which I know was updated to painterResource (I followed some other threads above about it) I currently have ended up with this but it doesn't compile:
Copy code
Icon(
    painterResource = painterResource(R.drawable.custom_right),
    contentDescription = "Right"
)
I'm missing something simple... aren't I? EDIT: Got it. It's
painter
not
painterResource
for the left side of the
=
I swear I got painterResource via autofill the first time Edit 2: Hm. Just got an autofill again for painted not painter. Curious if maybe slowness from kotlin/IDE is messing me up here.