I'm changing the theme of an activity in onCreate using setTheme (I'm
doing that even before calling super.onCreate(), as this is supposed
to be more reliable).

It does work in the sense that it changes the background and
foreground colors. However, my layout has a few elements that use
styles like textAppearanceLarge. Now Android's textAppearanceLarge
internally uses the textPrimaryColor - which is still unchanged by my
theme.

I tried to override the primary text color in my theme, but that
doesn't seem to work.

Here is the crucial part of the theme:

<style name="Theme.MyApp.White">
   <item name="android:background">@android:color/white</item>
   <item name="android:textColor">#000000</item>
</style>

The background appears white, plain TextViews appear black... but
TextViews using textAppearanceLarge are white, and as such invisible
(white on white).

I tried things like this:

   <item name="android:ColorPrimary">#000000</item>
   <item name="android:textColorPrimary">#000000</item>
   <item name="android:attr/textColorPrimary">#000000</item>

But none of those do anything. What's the magic trick?

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to