Compose SwiftUIv0.4.0
esc
GuideAPIGitHub
View modifier

overlay(_:)

Draws a view in front of a view.

iOS 17.0+macOS 14.0+tvOS 17.0+watchOS 10.0+
fun Modifier.overlay(style: ShapeStyle, ignoresSafeAreaEdges: Edge.Set = Edge.Set.all): Modifier

Overview

Modifier.overlay(style = ShapeStyle.…)

This is the Kotlin form of SwiftUI View.overlay(_:ignoresSafeAreaEdges:): SwiftUI documentation. In Swift it reads:

nonisolated func overlay<S>(_ style: S, ignoresSafeAreaEdges edges: Edge.Set = .all) -> some View where S : ShapeStyle

Topics

Overloads

fun Modifier.overlay(style: ShapeStyle, ignoresSafeAreaEdges: Edge.Set = Edge.Set.all): Modifier
SwiftUI View.overlay(_:ignoresSafeAreaEdges:)
fun Modifier.overlay(style: ShapeStyle, shape: Shape, fillStyle: FillStyle = FillStyle()): Modifier
SwiftUI View.overlay(_:in:fillStyle:)
fun Modifier.overlay(alignment: Alignment = Alignment.center, content: @Composable () -> Unit): Modifier
SwiftUI View.overlay(alignment:content:)