1.android:addStatesFromChildren="true"
Sets whether this ViewGroup's drawablestates also include its children's drawablestates
2.android:background="@android:drawable/edit_text" 编辑框的白的背景
3.android:textAppearance="?android:attr/textAppearanceLargeInverse" 大字体
4.android:background="@null" 不设置背景
5.android:background="@android:drawable/editbox_background"
编辑框背景 固定边框,不会变色

android:background="@android:drawable/editbox_background"

另一种背景
6.键盘不会全屏
textView.setImeOptions(EditorInfo.IME_FLAG_NO_EXTRACT_UI);
7.android:background="@android:drawable/dialog_frame" 系统dialog带边框的背景

8. EditTextet;
et.setError("hh", getResources().getDrawable(R.drawable.icon))

背景及边框处理

9.<TextView
style="?android:attr/listSeparatorTextViewStyle"
android:text="@string/listSeparatorTextViewStyle"
android:layout_marginTop="5dip"
/>

分割线效果

10.代码中设置指定单位的字体

warnView.setTextSize(TypedValue.COMPLEX_UNIT_SP, 18);

更多相关文章

  1. 如何实现Android 布局背景模糊化处理
  2. 去掉Button的默认背景
  3. Button或者ImageButton的背景设为透明或者半透明
  4. android实现标题栏、状态栏图标文字颜色及背景动态变化
  5. 自定义类似于listView中Item背景

随机推荐

  1. 从零开始学android开发- layout属性介绍
  2. Netty多语言(Java、Android(安卓)、C#、We
  3. ImageView android:scaleType属性详解
  4. win10 编译 Android(安卓)ffmpeg
  5. Android(安卓)各种音量的获取和设置
  6. Android(安卓)Studio常用快捷键、Android
  7. Android上层启动过程的几个关键点
  8. Android(安卓)android:exported = true
  9. Android(安卓)HttpURLConnection应用技巧
  10. Android(安卓)Opencore