I have created a button that has an image in it and it looks as follows:
The xml for the button is:
<Button
android:id="@+id/btn_Whishlist"
android:layout_width="0dp"
android:layout_height="0dp"
android:layout_marginStart="24dp"
android:layout_marginEnd="24dp"
android:background="@android:color/transparent"
android:drawableStart="@drawable/btn_whishlist"
android:gravity="start|center_vertical"
android:text="Whishlist"
android:textAllCaps="false"
android:textColor="@color/colorGray"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toStartOf="@+id/tv_WhishlistBooksCount"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintVertical_bias="0.0" />
Where the drawable is:
<?xml version="1.0" encoding="utf-8"?>
<layer-list xmlns:android="http://schemas.android.com/apk/res/android" >
<item
android:drawable="@drawable/ic_profile_whishlist"
android:width="24dp"
android:height="24dp"
/>
</layer-list >
I'm trying to add some space between the image of the heart to the text saying Whishlist however I can't figure out how to do it.
Any ideas?
Thank you