GenericShape

data class GenericShape : Shape
kotlin.Any
   ↳ androidx.ui.foundation.shape.GenericShape

Creates Shape defined by applying the provided builder on a Path.

Summary

Public constructors

<init>(builder: Path.(size: PxSize) -> Unit)

Creates Shape defined by applying the provided builder on a Path.

Public methods

Outline
createOutline(size: PxSize, density: Density)

Public constructors

<init>

GenericShape(builder: Path.(size: PxSize) -> Unit)

Creates Shape defined by applying the provided builder on a Path.

Parameters
builder: Path.(size: PxSize) -> Unit the builder lambda to apply on a Path

Public methods

createOutline

fun createOutline(
    size: PxSize,
    density: Density
): Outline
Parameters
size: PxSize the size of the shape boundary.
density: Density the current density of the screen.
Return
Outline of this shape for the given size.