zoukankan      html  css  js  c++  java
  • Bootstrap Edit 使用方法

    Getting Started

    <!-- rounded edit text -->
    <com.beardedhen.androidbootstrap.BootstrapEditText
                android:id="@+id/txtOne"
                android:layout_width="150dp"
                android:layout_height="wrap_content"
                android:layout_margin="10dp"
                android:hint="rounded" 
                bootstrapbutton:be_roundedCorners="true"
                android:gravity="center"
                bootstrapbutton:be_state="success"
    />
    

    The above code inserts a rounded bootstrap edit text with the state set to be succesfull. The following attributes can be added:

    bootstrapbutton:be_state="success" The state of the Bootstrap Edit Text e.g. warning, danger, success. Leave blank for default state.

    bootstrapbutton:be_roundedCorners="true" Whether the Bootstrap Edit Text should have rounded corners

    • and all the other variables for a typical edit text!

    You can also change the Bootstrap Edit Text programmatically!

    txtItem.setEnabled(false); change whether the edit text is enabled or disabled!

    txtItem.setState("default"); change the state of the Bootstrap Edit Text from warning, danger, success, or default.

    txtItem.setSuccess(); change the state of the Bootstrap Edit Text to success

    txtItem.setWarning(); change the state of the Bootstrap Edit Text to warning

    txtItem.setDanger(); change the state of the Bootstrap Edit Text to danger

    txtItem.setDefault(); change the state of the Bootstrap Edit Text to default

    • and all the functions for a typical edit text.
    • Note: You can also set up listeners and interact as per regular edit texts
  • 相关阅读:
    利用ssh的私钥登录Linux server
    PSR-2 代码风格规范
    MySQL的四种事务隔离级别
    table添加横向滚动条
    转换图片大小
    百度地图Label 样式:label.setStyle
    鼠标的几种常用样式
    百度地图API-自定义图标覆盖物
    微信公众号自定义菜单中可加入的表情
    微信公众号项目总结
  • 原文地址:https://www.cnblogs.com/boundary/p/3880760.html
Copyright © 2011-2022 走看看