Instance Method

padding(_:)

Pads the view using the specified edge insets.

Declaration

func padding(_ insets: EdgeInsets) -> some View

Parameters

insets

The edges to inset.

Return Value

A view that pads this view using the specified edge insets.

See Also

Adjusting the Padding of a View

func padding(CGFloat) -> View

Pads the view along all edge insets by the specified amount.

func padding(Edge.Set, CGFloat?) -> View

Pads the view using the specified edge insets.

struct EdgeInsets

The inset distances for the sides of a rectangle.