getDrawableByAttr

fun Context.getDrawableByAttr(@AttrRes attrRes: Int): Drawable

Returns a drawable that the given attrRes refers to.

Throws

if the given attribute cannot be found.