Hello guys, after having searched a lot and found little. I was trying to achieve how I wanted and I wanted to share the experience and result with you.
As the same Material Design documentation says.
A result Image Dropdown Menu similar to a Spinner, following the documentation. Next code:
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/txtAnswer"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.ExposedDropdownMenu"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/margin_top_15dp"
android:layout_marginEnd="10dp"
app:endIconDrawable="@drawable/ic_arrow_down"
app:hintTextAppearance="@style/styleFilterLabelLatoRegular"
app:layout_constraintEnd_toStartOf="@+id/txtAssignedTo"
app:layout_constraintStart_toStartOf="@+id/guideLineBegin"
app:layout_constraintTop_toBottomOf="@+id/txtSearchQuestionnaire">
<AutoCompleteTextView
android:id="@+id/actvTypesAnswer"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:inputType="none"
android:hint="@string/text_answer" />
Now a result as expected from an AutoCompleteTextView Image AutoCompleteTextView. Code xml.
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/txtSearchQuestionnaire"
style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox.ExposedDropdownMenu"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="@dimen/margin_top_15dp"
app:endIconMode="none"
app:hintTextAppearance="@style/styleFilterLabelLatoRegular"
app:layout_constraintEnd_toEndOf="@id/guideLineEnd"
app:layout_constraintStart_toStartOf="@+id/guideLineBegin"
app:layout_constraintTop_toBottomOf="@+id/txtPeriodActivation">
<AutoCompleteTextView
android:id="@+id/actvNameQuestionnaire"
style="@style/textAppearanceSettingInputEdittextFilter.Enabled"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:drawableEnd="@drawable/ic_search"
android:hint="@string/text_search_name_questionnaire" />
</com.google.android.material.textfield.TextInputLayout>
The only changes were to add the attribute app: endIconMode = "none"
in TextInputLayout and in the AutoCompleteTextView the attribute android: drawableEnd="@drawable/ic_search"
Excuse my level of English!!