2

Using macOS (11.3, M1 Mac mini) and an older Intel build of Emacs 27.1, when I load a file/buffer into Emacs, the path to the file/buffer shows up at the top of the window, above the toolbar: 27.1 But, using a newer "universal" build of Emacs 27.2, the file/buffer name shows up on the same row as the toolbar: 27.2 As you can see, the end of the file/buffer name can get cut off if the path is long and the window isn't wide enough.

How can I revert to the path-above-the-toolbar behavior shown in the 1st pic?

jimtut
  • 123
  • 4
  • If you don't get a satisfactory answer for how to compensate for this vanilla Emacs change, consider filing an enhancement request, using `M-x report-emacs-bug`. – Drew Apr 28 '21 at 16:24
  • Thanks, Drew. Is this a "vanilla Emacs change"? Meaning, is this a change that happened for ALL Emacs UI's from 27.1 to 27.2, or is it possibly just a macOS-specific change? Note that the pics are taken on the same Mac using the same macOS, so it's definitely not related to the macOS version, but maybe the build process/flags changed, not the Emacs source code. Would like to know if this is seen on other platforms. – jimtut Apr 28 '21 at 16:37
  • I have no idea. I said that based on what you wrote. It sounded like you changed nothing in your own code and you saw a change. But check with `emacs -Q`, to be sure the change is due to vanilla Emacs and not to some 3rd-party code you might be loading. – Drew Apr 28 '21 at 17:30

1 Answers1

2

It looks like you can change the default setting for whether or not the title (for Emacs, it's the buffer name) is over the toolbar with

defaults write -g NSWindowSupportsAutomaticInlineTitle -bool false

You can also do it just for Emacs with:

defaults write org.gnu.Emacs NSWindowSupportsAutomaticInlineTitle -bool false

although it's possible that your build of Emacs uses a different "domain" than org.gnu.Emacs.

I think that something like the following code change to Emacs in the right place would change the default appearance always:

if ( [NSToolbar instancesRespondToSelector:@selector(setToolbarStyle:)])
    [win setToolbarStyle: NSWindowToolbarStyleExpanded];

for an NSWindow object win at an appropriate time.

Win
  • 571
  • 3
  • 7
  • Wow. That is terrific, and something I just didn't know about Big Sur. There are other references to this, now that I know what to look for, like https://apple.stackexchange.com/questions/408475/revert-ui-on-big-sur. – jimtut Jun 07 '21 at 19:08
  • Just an update for others who stumble across this: this setting seems to have been removed in Monterey (12.0). It doesn't work for me any longer, and that seems consistent with some other new web searches turning up similar results. – jimtut Dec 27 '21 at 03:59
  • This stops working for Monterey. Does anyone know how to resolve this issue for Monterey? – Oliver Young May 18 '22 at 05:28
  • @jimtut. Did you figure out how to correct this for Monterey? I found that x86 build on Monterey works properly while Arm build of the emacs doesn't. – Oliver Young Oct 30 '22 at 23:56
  • Same here, I've just learned to live with it. :-( – jimtut Nov 03 '22 at 02:46