Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android - PreferenceActivity - Change color of Summary text of CheckBoxPreference

I am trying to change the summary text color of the CheckBoxPreference. I have changed the text color of the title by specifying a theme but it doesn't seem to be registering with the summary portion. Here is my theme.xml file:

<?xml version="1.0" encoding="UTF-8"?>
<resources xmlns:android="http://schemas.android.com/apk/res/android">
    <style name="settings_theme" parent="android:Theme.Light">
        <item name="android:textColor">@color/light_gray</item>
    </style>
</resources>

And I am calling this in the onCreate method of my settings activity:

setTheme(R.style.settings_theme);
like image 999
rplankenhorn Avatar asked Apr 03 '13 15:04

rplankenhorn


1 Answers

Add this to the style.xml in your theme:

<item name="android:textColorSecondary">@color/light_gray</item>
like image 200
Marko Niciforovic Avatar answered Nov 16 '22 08:11

Marko Niciforovic