先写一个EditText圆角的样式xml,路径:res/drawable/rounded_edittext.xml


http://schemas.android.com/apk/res/android"
android:shape="rectangle" android:padding="10dp">


android:bottomLeftRadius="15dp" android:topLeftRadius="15dp"
android:topRightRadius="15dp" />

---------------------------------------------------------------------------------------------------
然后把它加入到EditText控件的属性里去:


android:hint="@string/hint_operator_name"
android:background="@drawable/rounded_edittext" -----这里是重点
android:layout_width="250dip"
android:layout_height="wrap_content"
android:paddingTop="10dip"
android:paddingBottom="10dip"
android:gravity="center_vertical" />
-------------------------------------------------------

更多相关文章

  1. Android 基本控件 View 类的常用xml 属性(初级详解)
  2. android 控件-TextView用法整理
  3. Android Text控件之属性:android:textAppearance
  4. 项目中那些事|控件之TextView
  5. [android]控件Button常用属性
  6. Android 控件view的可见,不可见,隐藏的设置和区别
  7. android 输入法出现挤压屏幕、android输入键盘覆盖了屏幕控件的
  8. Android 控件使用参数集锦
  9. Android控件笔记——在界面中显示及输入文本信息

随机推荐

  1. android ubuntu jni so 报错Java_com_gcx
  2. android文件处理
  3. Android 通过按钮弹出系统菜单(通过Button
  4. Android――Shape详解
  5. Android仿音乐播放器功能
  6. Android studio使用心得(二)--- 打包签名
  7. android.os包中一些类的使用
  8. Android自定义view七时间轴(三)---纵向的图
  9. 打开android 系统联系人
  10. android解决部分手机无法通过uri获取到相