Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Setting the holographic theme in Honeycomb

I saw this post about using the new holographic themes on Honeycomb: Change theme according to android version

In my app, I have minSdkVersion="11" and targetSdkVersion="11". By default, I get a solid black background with light text. If I explicitly set Theme.Holo, on either application or activity, I still get the solid black, using this:

android:theme="@android:style/Theme.Holo"

However, I think Theme.Holo uses the gradient background I see in the HoneycombGallery example, set like this:

  case R.id.toggleTheme:
       if (mThemeId == android.R.style.Theme_Holo) {
            mThemeId = android.R.style.Theme_Holo_Light;
       } else {
            mThemeId = android.R.style.Theme_Holo;
  }

If that's the real holographic theme, how do I get it?

like image 272
suzannea Avatar asked Feb 23 '11 02:02

suzannea


1 Answers

You will get the fancy background only when hardware acceleration is turned on.

like image 160
Romain Guy Avatar answered Oct 14 '22 21:10

Romain Guy