2013-02-06 19 views
2

我在我的應用程序上使用android Theme.Sherlock.NoActionBar,它讓我感到輕鬆。有什麼方法可以讓我的應用程序獲得黑暗主題嗎?如何獲得一個黑暗的ActionBarSherlock主題?

<activity 
     android:name=".App" 
     android:label="@string/app_name" 
     android:configChanges="orientation|screenSize|screenLayout" 
     android:theme="@style/Theme.Sherlock.NoActionBar" > 

任何幫助將不勝感激。

回答

6

我記得黑暗的主題是actionbarsherlock默認主題,只需使用

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

android:theme="@style/Theme.Sherlock.NoActionBar" 

如果操作欄不需要

3

嘗試創建樣式,然後用它

<style name="ActionBarHomeItem" parent="Theme.Sherlock"> 
     <item name="android:windowActionBar">false</item> 
    </style> 

<activity 
     android:name=".App" 
     android:label="@string/app_name" 
     android:configChanges="orientation|screenSize|screenLayout" 
     android:theme="@style/ActionBarHomeItem" > 
+1

沒有預定義的主題名爲'Theme.Sherlock.Dark'。這只是'Theme.Sherlock'。 – Ahmad

+0

艾哈邁德,你是對的。修復。但你明白了 – SageNS