Package com.skydoves.landscapist
Class RememberPainterPluginsKt
-
- All Implemented Interfaces:
public final class RememberPainterPluginsKt
-
-
Method Summary
Modifier and Type Method Description final static PainterrememberDrawablePainter(Drawable drawable, List<ImagePlugin> imagePlugins)Remembers Drawable wrapped up as a Painter with a given the list of ImagePlugin. final static PainterrememberBitmapPainter(List<ImagePlugin> imagePlugins, ImageBitmap imageBitmap)Remembers ImageBitmap wrapped up as a Painter with a given the list of ImagePlugin. -
-
Method Detail
-
rememberDrawablePainter
@Composable() final static Painter rememberDrawablePainter(Drawable drawable, List<ImagePlugin> imagePlugins)
Remembers Drawable wrapped up as a Painter with a given the list of ImagePlugin. This function attempts to un-wrap the drawable contents and use Compose primitives where possible.
If the provided drawable is
null, an empty no-op painter is returned.This function tries to dispatch lifecycle events to drawable as much as possible from within Compose.
- Parameters:
drawable- A Drawable to be drawn.imagePlugins- A list of ImagePlugin that will be applied to the drawable painter.
-
rememberBitmapPainter
@Composable() final static Painter rememberBitmapPainter(List<ImagePlugin> imagePlugins, ImageBitmap imageBitmap)
Remembers ImageBitmap wrapped up as a Painter with a given the list of ImagePlugin.
- Parameters:
imagePlugins- A list of ImagePlugin that will be applied to the drawable painter.imageBitmap- An ImageBitmap to be drawn.
-
-
-
-