BackgroundKt
public final class BackgroundKt
Summary
Public methods |
|
|---|---|
static final @NonNull LayoutModifier |
@RequiresSchemaVersion(major = 1, minor = 500)Sets the background brush to |
static final @NonNull LayoutModifier |
background(@NonNull LayoutModifier receiver, @NonNull LayoutColor color)Sets the background color to |
static final @NonNull LayoutModifier |
clip(Clips the element to a rounded rectangle with corners specified in |
static final @NonNull LayoutModifier |
clip(Clips the element to a rounded rectangle with four corners with |
static final @NonNull LayoutModifier |
@RequiresSchemaVersion(major = 1, minor = 400)Clips the element to a rounded shape with |
static final @NonNull LayoutModifier |
@RequiresSchemaVersion(major = 1, minor = 400)Clips the bottom left corner of the element with |
static final @NonNull LayoutModifier |
@RequiresSchemaVersion(major = 1, minor = 400)Clips the bottom right corner of the element with |
static final @NonNull LayoutModifier |
@RequiresSchemaVersion(major = 1, minor = 400)Clips the top left corner of the element with |
static final @NonNull LayoutModifier |
@RequiresSchemaVersion(major = 1, minor = 400)Clips the top right corner of the element with |
Public methods
background
@RequiresSchemaVersion(major = 1, minor = 500)
public static final @NonNull LayoutModifier background(
@NonNull LayoutModifier receiver,
@NonNull ColorBuilders.Brush brush
)
Sets the background brush to brush.
background
public static final @NonNull LayoutModifier background(@NonNull LayoutModifier receiver, @NonNull LayoutColor color)
Sets the background color to color.
clip
public static final @NonNull LayoutModifier clip(
@NonNull LayoutModifier receiver,
@NonNull ModifiersBuilders.Corner corner
)
Clips the element to a rounded rectangle with corners specified in corner.
clip
public static final @NonNull LayoutModifier clip(
@NonNull LayoutModifier receiver,
@Dimension(unit = 0) float cornerRadius
)
Clips the element to a rounded rectangle with four corners with cornerRadius radius.
clip
@RequiresSchemaVersion(major = 1, minor = 400)
public static final @NonNull LayoutModifier clip(
@NonNull LayoutModifier receiver,
@Dimension(unit = 0) float x,
@Dimension(unit = 0) float y
)
Clips the element to a rounded shape with x as the radius on the horizontal axis and y as the radius on the vertical axis for the four corners.
clipBottomLeft
@RequiresSchemaVersion(major = 1, minor = 400)
public static final @NonNull LayoutModifier clipBottomLeft(
@NonNull LayoutModifier receiver,
@Dimension(unit = 0) float x,
@Dimension(unit = 0) float y
)
Clips the bottom left corner of the element with x as the radius on the horizontal axis and y as the radius on the vertical axis.
clipBottomRight
@RequiresSchemaVersion(major = 1, minor = 400)
public static final @NonNull LayoutModifier clipBottomRight(
@NonNull LayoutModifier receiver,
@Dimension(unit = 0) float x,
@Dimension(unit = 0) float y
)
Clips the bottom right corner of the element with x as the radius on the horizontal axis and y as the radius on the vertical axis.
clipTopLeft
@RequiresSchemaVersion(major = 1, minor = 400)
public static final @NonNull LayoutModifier clipTopLeft(
@NonNull LayoutModifier receiver,
@Dimension(unit = 0) float x,
@Dimension(unit = 0) float y
)
Clips the top left corner of the element with x as the radius on the horizontal axis and y as the radius on the vertical axis.
clipTopRight
@RequiresSchemaVersion(major = 1, minor = 400)
public static final @NonNull LayoutModifier clipTopRight(
@NonNull LayoutModifier receiver,
@Dimension(unit = 0) float x,
@Dimension(unit = 0) float y
)
Clips the top right corner of the element with x as the radius on the horizontal axis and y as the radius on the vertical axis.