Instance Method

padding(_:)

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

Declaration

func padding(_ length: CGFloat) -> some View

Parameters

length

The amount to inset this view on each edge.

Return Value

A view that pads this view by the amount you specify.

See Also

Adjusting the Padding of a View

func padding(EdgeInsets) -> View

Pads the view using the specified edge insets.

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

Pads the view using the specified edge insets.