android:TextView设置背景色和文本颜色
来源:互联网 发布:yy头像psd源码在线制作 编辑:程序博客网 时间:2024/05/21 18:42
设置TextView控件的背景色和文本颜色很简单,如下:
textView01 = (TextView)findViewById(R.id.textView01); textView02 = (TextView)findViewById(R.id.textView02); //设置背景色 textView01.setText("设置了背景色黑色"); //从资源文件中加载颜色 textView01.setBackgroundDrawable( getResources().getDrawable(R.drawable.green)); //设置文本颜色(如透明色:Color.TRANSPARENT) textView02.setTextColor(Color.MAGENTA); textView02.setText("设置文本颜色");
原文地址:android:TextView设置背景色和文本颜色 | http://orgcent.com/android-textview-background-color/
- android:TextView设置背景色和文本颜色
- android TextView 设置部分文字背景色和文字颜色
- android TextView 设置部分文字背景色和文字颜色
- android TextView 设置部分文字背景色和文字颜色
- Android TextView 设置部分文字背景色和文字颜色
- android TextView 设置部分文字背景色和文字颜色
- Android TextView设置背景色和边框
- android:为TextView添加样式——下划线,颜色,设置链接样式及前背景色
- android:为TextView添加样式——下划线,颜色,设置链接样式及前背景色
- android:为TextView添加样式——下划线,颜色,设置链接样式及前背景色
- android:为TextView添加样式——下划线,颜色,设置链接样式及前背景色
- android:为TextView添加样式——下划线,颜色,设置链接样式及前背景色
- android:为TextView添加样式——下划线,颜色,设置链接样式及前背景色
- android:为TextView添加样式——下划线,颜色,设置链接样式及前背景色
- android 中TextView设置部分文字背景色和文字颜色
- Android TextView 设置部分文字背景色和文字颜色(转)
- TextView设置部分文字背景色和文字颜色
- 窗体的背景色和文本的背景色
- c语言解 等分液体
- C++ operator关键字(重载操作符)
- Mac知识点
- Excel2003和Excel2007对下拉选择和下拉级联选择的操作以及java程序的调用
- android获取屏幕分辨率大小(DisplayMetrics)
- android:TextView设置背景色和文本颜色
- brctl 配置网桥
- android隐藏IME(输入法)输入框
- android:TextView设置文本样式和超链接
- Java实现HTTP文件下载和图片(验证码)浏览
- 使用jxl读写Excel文件
- 导致等待事件的常见原因及解决方案
- 二进制--补码简介
- 控制流量-滑动窗口机制