Remove 'Show/Hide tab bar' menu item
Asked Answered
S

1

8

The latest version of macOS Sierra adds a 'Show/Hide tab bar' menu item to the 'View' menu.

View menu item

It does this dynamically.

My application already includes its own tab bar using the MMTabBarView library. I would prefer to continue using this library as it gives me backwards compatibility with tabs, plus the ability to do some customization to tabs.

I'm not seeing anything in apples NSDocument or NSDocumentController documentation on removing this menu item.

Does anyone have any suggestions as to how I can remove it?

NOTE: I do not want to simply disable it, I am looking to remove it completely. (Or I guess not have it added in the first place).

Sankey answered 9/11, 2016 at 14:0 Comment(1)
Does this answer your question? How do I disable the Show Tab Bar menu option in Sierra apps?Esp
J
13

In Interface Builder, open the attributes of your NSWindow and you'll see an option called "Tabbing Mode". Set it to Disallowed.

Jock answered 9/11, 2016 at 14:15 Comment(3)
Ahhhh, the window itself. I didn't think of that. Thank you!Sankey
In the SwiftUI you can do window.tabbingMode = .disallowedFatherhood
For Xamarin.Forms applications we need to do this in the AppDelegate creation of the window and include TabbingMode= NSWindowTabbingMode.Disallowed. Making the changes in Xcode has no effect since we are using our own NSWindow.Berezniki

© 2022 - 2024 — McMap. All rights reserved.