我想要更改AlertDialog(Holo Theme)中出現的藍色標題和藍線的顏色,我可以通過查找來更改標題的顏色android styles.xml和themes.xml,但我找不到任何屬性或樣式,我可以使用/更改來改變我的XML的顏色。如何更改AlertDialog中的藍線(Holo Theme)
以下是我使用更改標題顏色
<style name="myAlertDialog" parent="android:Theme.Holo.Dialog">
<item name="android:windowBackground">@android:color/transparent</item>
<item name="android:windowTitleStyle">@style/myAlertDialogTitleStyle</item>
</style>
<style name="myAlertDialogTitleStyle">
<item name="android:maxLines">1</item>
<item name="android:scrollHorizontally">true</item>
<item name="android:textAppearance">@style/myAlertDialogTitleStyleTextAppearance</item>
</style>
<style name="myAlertDialogTitleStyleTextAppearance">
<item name="android:textSize">22sp</item>
<item name="android:textColor">#ffff8800</item>
</style>
此解決方案是否適合您? – Gopinath
我不知道你的答案是否解決這個問題http://stackoverflow.com/questions/14439538/how-can-i-change-the-color-of-alertdialog-title-and-the-color-of-the -line-under –
@forsubhi我認爲它確實解決了這個問題,但是我想在發佈答案之前自己測試一下,以便100%確定。 (除非你已經嘗試過?在這種情況下,我會很樂意發佈我的答案) –