Android自定义属性,attr format取值类型
2014-11-24 07:34:54
·
作者:
·
浏览: 2
1. reference:参考某一资源ID。
(1)属性定义:
background
" format = "
reference" />
(2)属性使用:
android:layout_width = "42dip"
android:layout_height = "42dip"
android:background = "@drawable/图片ID"
/>
2. color:颜色值。
(1)属性定义:
textColor" format = "color" />
(2)属性使用:
android:layout_width = "42dip"
android:layout_height = "42dip"
android:textColor = "#00FF00"
/>
3. boolean:布尔值。
(1)属性定义:
focusable" format = "boolean" />
(2)属性使用: