Package-level declarations
Types
Link copied to clipboard
open class LiveDataDrawable(val liveData: LiveData<Drawable>, initialDrawable: Drawable? = null) : DrawableWrapper
Link copied to clipboard
open class RemoteDrawable(context: Context, uri: Uri, placeholder: Drawable? = null, error: Drawable? = null, targetView: ImageView? = null) : LiveDataDrawable
A LiveDataDrawable that resolves its LiveData contents from the given URI.
Link copied to clipboard
data class RemoteDrawableResolver(uri: Uri, placeholder: DrawableResolver? = null, error: DrawableResolver? = null) : DrawableResolver
A DrawableResolver that resolves a drawable from the given uri.
Link copied to clipboard
Link copied to clipboard
A DrawableResolver that creates a Drawable with a text retrieved from a StringResolver.
Functions
Link copied to clipboard
suspend fun Drawable.getBrightnessAdjustedDominantColor(@ColorInt defaultColor: Int, dispatcher: CoroutineDispatcher = Dispatchers.Default): Int
Returns the drawable's dominant color with a brightness adjustment. If no dominant color is available it falls back to defaultColor. The brightness value of the dominant color is adjusted to an average value in between the original one and the defaultColor brightness value. Therefore, the returned dominant color can be brighter or darker than the original dominant color.