Style Modifiers

Apply built-in styles to different types of views.

Overview 概要

SwiftUI defines built-in styles for certain kinds of views, and chooses the appropriate style for a particular presentation context. For example, a Label might appear as an icon, a string title, or both, depending on factors like the platform, whether the view appears in a toolbar, and so on.

You can override the automatic style by using one of the style modifiers. These modifiers typically propagate through container views, so you can wrap an entire view hierarchy in a style modifier to affect all the views of the given type within the hierarchy.

Some view types enable you to create custom styles, which you also apply using these style modifiers.

Topics 話題

Controls

Indicators

Text テキスト

Collections

Presentation

Groups

See Also 参照

Drawing Views