布局文件(res/layout/.xml)中指定控件的style属性:
<TextView
style="@style/StyleType1"
...
/>
定义样式(res/values/style.xml):
<style name="StyleType1">
<item name="android:textSize">18sp</item>
<item name="android:textColor">#EC9237</item>
</style>
定义样式的语法:
<style name=string [parent=string ]>
<item name=string>Hex value | string value | reference</item>
</style>