I am using ActionBarSherlock as follows:
Context context = getSupportActionBar().getThemedContext();
ArrayAdapter<CharSequence> list = ArrayAdapter.createFromResource(
context, R.array.dropdown, R.layout.sherlock_spinner_item);
list.setDropDownViewResource(R.layout.sherlock_spinner_dropdown_item);
getSupportActionBar().setNavigationMode(ActionBar.NAVIGATION_MODE_LIST);
getSupportActionBar().setListNavigationCallbacks(list, this);
However, I cannot figure out how to style the textcolor of the selected item in the dropdown. My styles file looks like:
<style name="MyTheme.ActionBar.TitleTextStyle" parent="TextAppearance.Sherlock.Widget.ActionBar.Title">
<item name="android:textColor">#ABABAB</item>
</style>
But this only affects the title text, not that of the spinner.
Any ideas of the attribute I need to override?
Thanks,
Stephen
You must edit the Style at the sherlock library : res/values/abs_string.xml
<style name="Sherlock.__Widget.Holo.DropDownItem" parent="Widget">
<item name="android:textAppearance">@style/TextAppearance.Sherlock.Widget.DropDownItem</item>
<item name="android:paddingLeft">8dp</item>
<item name="android:paddingRight">8dp</item>
<item name="android:gravity">center_vertical</item>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With