颜色的取值范围是0~256,给ARGB每一位随机生成一个int值
Random random = new Random();
int color = Color.argb(255,random.nextInt(256),random.nextInt(256),random.nextInt(256));
layout.setBackgroundColor(color);
颜色的取值范围是0~256,给ARGB每一位随机生成一个int值
Random random = new Random();
int color = Color.argb(255,random.nextInt(256),random.nextInt(256),random.nextInt(256));
layout.setBackgroundColor(color);