Contents

ToolbarTitleAlignment

A preferred alignment for a navigation bar’s title.

Declaration

struct ToolbarTitleAlignment

Overview

Use values of this type with the toolbarTitleAlignment(_:) modifier to override the title alignment the system would use.

NavigationStack {
    ContentView()
        .navigationTitle("Library")
        .toolbarTitleAlignment(.center)
}

To read the alignment the system actually used, see toolbarTitleAlignment.

Topics

Type Properties