공부방/Android2020. 1. 27. 21:04How to change color stroke and solid programmatically ?
Stroke color : val drawable = view.background as GradientDrawable drawable.setStroke(3, ContextCompat.getColor(context, R.color.colorWhite)) // width and stroke color Solid color : val drawable = view.background as GradientDrawable drawable.setColor(ContextCompat.getColor(context, R.color.colorWhite)) // solid color resource_border.xml