【问题标题】:Xamarin Android TimePicker how to change underline color using StylesXamarin Android TimePicker 如何使用样式更改下划线颜色
【发布时间】:2020-11-26 05:10:33
【问题描述】:

目前下划线颜色为白色,我该如何更改颜色。

我已经使用我非常喜欢的样式查看了这个解决方案,但是我需要设置哪个属性来更新这个下线颜色? Xamarin Android - Change colors for TimePicker keyboard view

【问题讨论】:

    标签: xamarin xamarin.android


    【解决方案1】:

    一般来说,样式中的一个属性可能会影响多个控件的外观。

    例如在您的问题中,您可以尝试在样式中定义以更改下划线颜色,例如:

    <style name="Theme.picker" parent="Theme.AppCompat.Light.Dialog">
      <item name="colorControlNormal">#ff00ff</item> // the underline normal color which no focus
      <item name="colorControlActivated">#ff0000</item>// the underline activate color which focus
    </style>
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2012-09-15
      • 1970-01-01
      • 1970-01-01
      • 2018-09-11
      • 1970-01-01
      • 2011-12-02
      相关资源
      最近更新 更多