ShapeDrawable

class ShapeDrawable(shape: Shape, isLtr: Boolean, density: Float, width: Int = 0, height: Int = 0) : Drawable

Creates a Drawable out of the provided shape.

Parameters

shape

the Shape used as a Drawable.

isLtr

whether the device layout is left-to-right.

density

the pixel density of the device screen.

width

the width of the Drawable.

height

the height of the Drawable.

Constructors

Link copied to clipboard
constructor(context: Context, shape: Shape, width: Int = 0, height: Int = 0)
constructor(shape: Shape, isLtr: Boolean, density: Float, width: Int = 0, height: Int = 0)

Properties

Link copied to clipboard

The Paint used to draw the shape.

Functions

Link copied to clipboard
open override fun draw(canvas: Canvas)
Link copied to clipboard
open override fun getIntrinsicHeight(): Int
Link copied to clipboard
open override fun getIntrinsicWidth(): Int
Link copied to clipboard
open override fun getOpacity(): Int
Link copied to clipboard
open override fun setAlpha(alpha: Int)
Link copied to clipboard
open override fun setColorFilter(colorFilter: ColorFilter?)
Link copied to clipboard
open override fun setState(stateSet: IntArray): Boolean
Link copied to clipboard
open override fun setTintList(tint: ColorStateList?)