Instance Method

touchBarItemPrincipal(_:)

Sets the view as having special significance to the TouchBar.

Declaration

func touchBarItemPrincipal(_ principal: Bool = true) -> some View

Discussion

The provided item will be placed in the center of the row. You can specify a principal view for multiple visible bars; however, the system only honors the request for one of them.

See Also

Configuring Touch Bar Views

func touchBar<Content>(content: () -> Content) -> View

Sets the content that the Touch Bar displays.

func touchBar<Content>(TouchBar<Content>) -> View

Sets the touch bar and its content to be shown in the Touch Bar when applicable.

func touchBarCustomizationLabel(Text) -> View

Sets a user-visible string identifying the view’s functionality.

func touchBarItemPresence(TouchBarItemPresence) -> View

Sets the behavior of the view when being customized by the user.