How to set a mipmap icon on Floating Action Button?

163 views Asked by At

My FAB is only showing the icon when I'm using a drawable resource, but not when I'm using a mipmap resource.

With a drawable resource:

Screenshot of Android Studio Layout Editor with FAB drawable

With a mipmap resource:

Screenshot of Android Studio Layout Editor with FAB mipmap

1

There are 1 answers

1
Oxorion On

Replace : android:src="@mipmap/your_mipmap" with : android:foreground="@mipmap/your_mipmap"