Skip to content Skip to sidebar Skip to footer

Changing Spinner Text Color Based On Background Color

I have a custom spinner layout with an image and a text view but I noticed that depending on the manufacturers skin you cant see the text because of the color ie. white on white, b

Solution 1:

Use the default text color of the current theme (stored in the resource ID android.R.attr.textColorPrimary) :

<TextView android:id="@+id/icon_txt"
    android:textColor="?android:attr/textColorPrimary"
    ... />

Solution 2:

I think changing your theme changes the appearance of the listview.

I was also stucked at this point but what i did was that i made a new android app project and selected blank activity (in place of empty activity) and it worked (i know that's not a good solution but it solved my issue)

Post a Comment for "Changing Spinner Text Color Based On Background Color"