Good Night! I want to define a custom theme for my Spinner since the background of the application has a dark color, I would like to set a clear color for the spinner button and for the texts, but I can not accomplish this feat by setting a theme yet, follow the code that I need to start by just changing the text colors, from the spinner button to white.
<Spinner
android:id="@+id/sp_cargo"
android:layout_width="200dp"
android:layout_height="wrap_content"
android:layout_marginLeft="8dp"
android:layout_marginTop="8dp"
android:theme="@style/MySpinner"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toBottomOf="@+id/textView" />
The theme:
<style name="MySpinner" parent="Base.Widget.AppCompat.DropDownItem.Spinner">
<item name="android:textColor">@color/secondaryTextColor</item>
<item name="android:textSize">@dimen/txt_spinner</item>
<item name="colorButtonNormal">@color/primaryColor</item>
</style>