Toolbar item right aligned with CustomNSToolbarMBS

I’m playing around with the example “Toolbar buttons”. I’ve removed all items except the play button. How do I get the button to the left side of the toolbar?

You don’t. The toolbar alignment is part of that style.

Now… there is a way to add one or two buttons to the left, but you’ll need declares or other MBS methods to do that.

1 Like

Just to be clear, what you’ve got there is called a Unified toolbar. That is, it’s combined with the title bar. Any changes you make with this code is only available on macOS 11 and above.

The property I was referring to is called “Navigational”, but it’s really meant for items like Back and Forward, and is applied to the buttons themselves.

https://developer.apple.com/documentation/appkit/nstoolbaritem/3622481-navigational?language=objc

1 Like

Ah, the unified toolbar version is always right aligned.