【发布时间】:2013-08-09 20:38:12
【问题描述】:
我有一个ListView,每行包含一个TextView 和一个NumberPicker。
每当我启动活动时,NumberPicker 的数字都是白色的(与背景颜色相同)。
我尝试应用here、here 和here 建议的样式;无济于事。
还有其他建议吗?
-
NumberPicker.xml
<NumberPicker
android:id="@+id/npMaterialAmount"
android:layout_alignParentRight="true"
android:layout_width="wrap_content"
android:layout_height="75dp"
style="@style/npColour"/>
-
尝试样式 1:
<style name = "npColour" >
<item name = "android:textColor">#000000</item>
</style>
-
尝试样式 2:
<style name = "npColour" parent ="@android:style/Theme.Holo.Light">
</style>
-
...而且名单还在继续...
【问题讨论】:
-
好吧,你将
NumberPicker的颜色设置为白色-><item name = "android:textColor">#000000</item>,你为什么想知道为什么它是白色的? -
黑色的十六进制代码是#000000
-
@g00dy 供您参考 > color-hex.com/color/000000
-
找不到与
'@style/Theme.Holo.NumberPicker'匹配的资源
标签: android numberpicker