I have the following layout XML:
<android.support.v7.widget.AppCompatSpinner
android:id="@+id/content_spinner"
style="@style/Widget.AppCompat.Spinner.Underlined"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_margin="10dp"
android:layout_marginEnd="8dp"
android:layout_marginLeft="8dp"
android:layout_marginRight="8dp"
android:layout_marginStart="8dp"
android:layout_marginTop="8dp"
android:background="@drawable/border"
android:entries="@array/books"
android:spinnerMode="dropdown"
android:theme="@style/large_spinner"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
And @style/large_spinner
looks like this:
<style name="large_spinner" parent="Widget.AppCompat.Light.DropDownItem.Spinner">
<item name="android:paddingStart">0dp</item>
<item name="android:paddingEnd">0dp</item>
<item name="android:textColor">@color/nearlyBlack</item>
<item name="android:textSize">30sp</item>
<item name="android:drawableRight">@drawable/ic_menu_camera</item>
</style>
Which gives me the camera
icon to the right of the spinner, which is want. However when I drop down the spinner the icon is on every single item, which I dont want. I just want the icon to the right on the spinner, not in every single item.
How can i achieve this?