I have a Button which takes as input the text attribute of the button self. I need to embellish this button with an image that covers a part of the button. If I do it I expect to be still able to click the button surface, but is not the case, because the ImageView
above the button is not clickable. I want that the ImageView or View( or whatever) is for aesthetics reasons on top of the button but that is completely ignored
when I click on it, it would be like does not exist, taking as click the value of the button below, so that I can click all the surface of the Button comprehending the image on top taking only the input of the Button
<android.support.constraint.ConstraintLayout
android:id="@+id/ordinateur"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginBottom="4dp"
app:layout_constraintBottom_toBottomOf="parent">
<Button
android:layout_width="0dp"
android:layout_width="wrap_content"
android:id="@+id/numer_een"
android:background="@drawable/le_click"
android:layout_marginEnd="4dp"
android:paddingBottom="24dp"
android:text="1"
android:onClick="ici"
app:layout_constraintEnd_toStartOf="@+id/contraint1"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="@+id/constraint2">
</Button>
//here an image
</android.support.constraint.ConstraintLayout>