2011.09.01——— android 透明显示
参考:http://zhangkun716717-126-com.iteye.com/blog/814739
http://tracyhuyan.iteye.com/blog/710591


设置透明效果 大概有三种


1、用android系统的透明效果
android:background="@android:color/transparent"


例如 设置按钮
<Button android:background="@android:color/transparent"   android:text="@+id/Button01"   android:id="@+id/Button01"   android:layout_width="wrap_content"   android:layout_height="wrap_content"   android:textColor="#ffffff" /> 


2、用ARGB来控制

半透明<Button android:background="#e0000000" />透明<Button android:background="#00000000" />



3、设置alpha

View v = findViewById(R.id.content);//找到你要设透明背景的layout 的idv.getBackground().setAlpha(100);//0~255透明度值




更多相关文章

  1. Android(安卓)滚动Tab
  2. 2011.09.01——— android 透明显示
  3. Android中按钮点击效果显示
  4. androidの布局控件居于最底部实现
  5. Android(安卓)TimePicker
  6. android 资料收集大全
  7. EditeText标签字体大小设置 是否可编辑
  8. textview 小结
  9. Android之拍照

随机推荐

  1. Android至ViewPager添加切换动画——使用
  2. Activity 四种启动模式详细介绍
  3. 下载和安装Android Studio搭建Android集
  4. Android 日历提供器(三)
  5. [译]开/闭原则在Android中的实践
  6. 关于Android中layout的层次问题-----
  7. Android(安卓)将View 转化为bitmap 图片
  8. (android)system ui 内存优化
  9. 在android style.xml文件中使用自定义属
  10. 使用Android studio个人总结