开发者

Using Color Reference in Styles

开发者 https://www.devze.com 2023-04-04 05:04 出处:网络
Why can\'t I use a reference to a color in my styles.xml? 开发者_如何学C <style name=\"LabelStyle\">

Why can't I use a reference to a color in my styles.xml?

开发者_如何学C
<style name="LabelStyle">
    <item name="android:textSize">12sp</item>
    <item name="android:textColor">@color/Brown</item>
    <item name="android:textStyle">bold</item>
</style>

It works fine with a defined color such as #FFFFFF, but a reference to a color does not show up.


I apologize, the fore mentioned, does work. I was just using it the wrong way. You can reference colors using a reference color exactly the way I described.

0

精彩评论

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