I need to add an underline below my Spinner. From these links:
I have implemented the below:
In reminder_dialog_fragment.xml
<android.support.v7.widget.AppCompatSpinner
android:id="@+id/spinner_1"
android:layout_width="match_parent"
android:layout_height="wrap_content"
style="@style/Widget.AppCompat.Spinner.Underlined"
android:theme="@style/MySpinnerTheme" />
In styles.xml
<style name="MySpinnerTheme" parent="Theme.AppCompat.Light.DarkActionBar">
<!-- set color for underline below Spinner -->
<item name="colorControlActivated">#ffcfd8dc</item>
<item name="colorControlHighlight">#ffcfd8dc</item>
<item name="colorControlNormal">#ffcfd8dc</item>
</style>
I managed to display underline
below Spinner & change the underline's color
. But during spinner onclick / highlighted
, there is some animation effect
on Spinner:
Ripple
effect on thetriangle
(right side of Spinner)The
underline
below Spinner becomebold
How can I remain the effect of (1), but disable the effect of (2)?
In other words, I want to prevent the underline
become bold
when Spinner is clicked.