文档(或任何人)是否讨论了默认的 dpi 值
android:textAppearance="?android:attr/textAppearanceLarge"
android:textAppearance="?android:attr/textAppearanceMedium"
android:textAppearance="?android:attr/textAppearanceSmall"
SDK 中的小部件?
换句话说,我们可以在不使用android:textAppearance属性的情况下复制这些文本视图的外观吗?
android:textAppearance
见android sdk目录。
在\platforms\android-X\data\res\values\themes.xml:
\platforms\android-X\data\res\values\themes.xml
<item name="textAppearanceLarge">@android:style/TextAppearance.Large</item> <item name="textAppearanceMedium">@android:style/TextAppearance.Medium</item> <item name="textAppearanceSmall">@android:style/TextAppearance.Small</item>
在\platforms\android-X\data\res\values\styles.xml:
\platforms\android-X\data\res\values\styles.xml
<style name="TextAppearance.Large"> <item name="android:textSize">22sp</item> </style> <style name="TextAppearance.Medium"> <item name="android:textSize">18sp</item> </style> <style name="TextAppearance.Small"> <item name="android:textSize">14sp</item> <item name="android:textColor">?textColorSecondary</item> </style>
TextAppearance.Large表示样式是从样式继承的TextAppearance,如果您想查看样式的完整定义,还必须对其进行跟踪。
TextAppearance.Large
TextAppearance
链接:http: //developer.android.com/design/style/typography.html