首页 > 移动平台 > 详细

Android RadioButton代码去掉左边默认显示的圆圈

时间:2016-05-04 10:21:31      阅读:658      评论:0      收藏:0      [点我收藏+]
Drawable drawable = context.getResources().getDrawable(
R.drawable.radiobg);
drawable.setBounds(0, 0,
drawable.getIntrinsicWidth(),
drawable.getIntrinsicHeight());
RadioButton radioButton=new RadioButton(context);
radioButton.setButtonDrawable(android.R.color.transparent);
radioButton.setTextSize(16);
radioButton.setTextColor(Color.parseColor("#393939"));
radioButton.setCompoundDrawables(null,null,drawable,null);
radioButton.setText(deliverytime.getName());
 
这样就可以写成自己需要的样式
 
http://blog.163.com/keep_run/blog/static/205557036201322724120140/

Android RadioButton代码去掉左边默认显示的圆圈

原文:http://www.cnblogs.com/Jingerxin/p/5457252.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!