美文网首页
design控件之TextInputLayout

design控件之TextInputLayout

作者: Avalon1 | 来源:发表于2017-02-06 18:00 被阅读18次

属性相关:xml

counterEnabled:是否显示计数器 
counterMaxLength 计数器最大值                       
errorEnabled    错误提示是否可用                                                   
hintAnimationEnabled       提示的动画                                  
hintEnabled                  是否允许输入的时候显示提示到上方
hintTextAppearance 设置提示文字的外观
passwordToggleContentDescription
passwordToggleDrawable 自定义的替换系统密码切换的眼睛图片
passwordToggleEnabled   是否允许显示密码切换
passwordToggleTint       眼睛按钮着色
TextInputLayout_passwordToggleTintMode 着色的模式

附:EditText 修改下划线颜色的方法。
建议:不要直接修改appTheme,自己写个style然后

<style name="et_pass" parent="AppTheme">
<item name="colorControlActivated">@color/colorAccent</item>
<item name="colorControlNormal">@android:color/darker_gray</item></style>

在EditText中设置theme属性

相关文章

网友评论

      本文标题:design控件之TextInputLayout

      本文链接:https://www.haomeiwen.com/subject/kpsuittx.html