Android的CardView带有自定义阴影颜色 [英] Android CardView with a custom shadow color

查看:12290
本文介绍了Android的CardView带有自定义阴影颜色的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有可能改变周围的CardView阴影的颜色?主要用于标记选择的卡,因为它被点亮

Is it possible to change the color of the shadow around the CardView? Mainly used to mark selected the card as it were lighted on?

应该对L和pre-L器件有效。

Should be valid on L and pre-L devices.

的23/02/2016编辑:目前它仍然是不可能的,还在寻找一个解决方案

EDIT of 23/02/2016: at the moment it is still not possible, still looking for a solution.

推荐答案

CardView阴影颜色在CardView库的资源定义。您可以通过重新定义自己的项目资源价值超越他们,但你不能用code动态地改变它们。

CardView shadow colors are defined in the resources of the CardView library. You can override them by redefining the resource value in your own project but you can not change them dynamically by code.

这篇关于Android的CardView带有自定义阴影颜色的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆