Answer the question
In order to leave comments, you need to log in
How to completely replace the Floating Button in Android with your own image?
How to completely replace the image of a round Floating Button in your Android application with your own image?
Answer the question
In order to leave comments, you need to log in
It is possible via XML:
android:src="@drawable/your_icon" // change background icon
app:backgroundTint="@color/your_color" // change background color
mFab.setImageResource(R.drawable/your_icon);
Do you have a given icon displaying the entire FAB using this code? Those. can I put a png image with a transparent edge, and visually the button will be of an arbitrary shape? I only fit a small image in the center of the FAB.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question