Type Property 型プロパティ

foreground

The foreground style in the current context.

Declaration 宣言

static var foreground: ForegroundStyle { get }
Available when Self is ForegroundStyle.

Discussion 議論

Access this value to get the style SwiftUI uses for foreground elements, like text, symbols, and shapes, in the current context. Use the foregroundStyle(_:) modifier to set a new foreground style for a given view and its child views.

For information about how to use shape styles, see ShapeStyle.