Weird problem with android theming
<p>I am a newbie when compared to android development and i am just going through the sample projects to get a hang of it. I just tried to copy a style from Wikitionary( a sample app that comes with android SDK).</p>

<pre><code>&lt;style name="LookupTheme" parent="@android:style/Theme.Light"&gt;
   &lt;item name="android:windowBackground"&gt;@drawable/lookup_bg&lt;/item&gt;
 &lt;/style&gt;
</code></pre>

<p>And specified this as the default theme in manifest file. This produced an effect, like this.<img src="http://i.stack.imgur.com/LQFS9.png" alt="enter image description here"></p>

<p>This is exactly what i wanted.. Now i have added a preference page to allow user to choose from a list of themes to be applied. Hence, i removed the theme attribute from manifest file(to use default theme) and i tried to apply theme programatically. Like this</p>

<pre><code>SharedPreferences sPref = PreferenceManager.getDefaultSharedPreferences(act.getApplicationContext());
    String themeid = sPref.getString("theme_pref", "1");
    int themeID = Integer.valueOf(themeid);
    if(themeID== 2){
        Log.d(Constants.LOG_TAG, "Light theme have been choosen");
        act.setTheme(R.style.LookupTheme);
    }
</code></pre>

<p>Now the same theme gets applied programatically(as opposed to a declarative approach) and produces an effect like this.
<img src="http://i.stack.imgur.com/9qDtT.png" alt="enter image description here"></p>

<p>Can someone explain what is wrong here?</p>
