开发者

finding the correct style in R.attr

using:

android:textAppearance="?android:attr/...."

I would like to style a TextView to look like the default style of the "summary" attribute within a PreferenceScreen.

using the styles from this official list开发者_开发技巧, I have tried "summary" and "summaryOn", but neither of them looks like the default style for summaries. Can anyone explain why, or suggest which one I should be using?


There isn't a theme attribute that refers to the specific semantic of preference summary text, preferences use ?android:attr/textAppearanceSmall as illustrated here: http://goo.gl/3yZmx (This is the layout file used by the Android framework for preference items.)


The correct way to reference an ID is using @.

Such as @string/my_string

Since you wish to reference an ID defined by Android directly, try this:

android:textAppearance="@android:id/summary"
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜