ghostty icon indicating copy to clipboard operation
ghostty copied to clipboard

Ghostty loses macos titlebar info on theme change

Open roguesherlock opened this issue 1 year ago • 6 comments

I don't know how to describe this but when you have macos-titlebar-tabs = true, change the theme and reload the config, ghostty seems to lose the title bar info. Here's a quick video that describes it better,

https://github.com/mitchellh/ghostty/assets/5683543/3772391c-24d3-494b-b485-f1fe3bdabd12

As shown in the video, I have two tabs open and when I change the theme and reload the config, it seems to only show one tab in the titlebar even though the second is still active. Does it make sense?

p.s. I think it was working fine two releases ago if it helps

roguesherlock avatar May 23 '24 07:05 roguesherlock

Also happens on restart with window-save-state = always. Opening a new tab will show the correct tabbar (including the old tabs), but switching to one of the old tabs loses the information about the other tabs.

Doesn't happen with native tabs.

clason avatar May 23 '24 07:05 clason

Reproduced. Thanks.

mitchellh avatar May 27 '24 03:05 mitchellh

This issue also occurs when switching between light and dark modes while window-theme = system is set.

eddiegrau avatar Dec 22 '24 17:12 eddiegrau

The issue I encountered probably has the same origin.

Currently by default (ghostty +show-config --default) title bar style is set to transparent (macos-titlebar-style = transparent).

Steps to reproduce:

  1. Set system theme to Dark.
  2. Set dark/light theme in ghostty config: theme = dark:Argonaut,light:Alabaster.
  3. Start ghostty. Title bar is dark.
  4. Hit cmd+N to open up new ghostty window. Title bar is still dark.
  5. Hit cmd+shift+, to reload config (note: no config changes were made since ghostty started in step 3).
  6. Hit cmd+N to open up new ghostty window. Title bar is white (bug!).

Observations:

  • Setting theme = Argonaut does not cause title bar be white in step 6.
  • Issue is not reproduced with macos-titlebar-style = native.
  • Issue is reproduced with macos-titlebar-style = tabs.

UPD: I just reproduced it by opening new tab instead of new window.

e1senh0rn avatar Dec 27 '24 23:12 e1senh0rn

Probably interesting gotcha: For me the problems only appear if background-opacity is not 1.

Minimal reproduceable config:

theme = light:BlulocoLight,dark:BlulocoDark
background-opacity = 0.9 
macos-titlebar-style = tabs

uloco avatar Apr 15 '25 10:04 uloco

Probably interesting gotcha: For me the problems only appear if background-opacity is not 1.

Minimal reproduceable config:

theme = light:BlulocoLight,dark:BlulocoDark
background-opacity = 0.9 
macos-titlebar-style = tabs

it happened for me too, after i put the background-opacity to 1, it solve the issue

luberius avatar Jun 07 '25 00:06 luberius

Setting the opacity to 1 solved a part oft this, but not all. There is still the issues, that when the macos theme changes in the background and the terminal is not focused and there are other, the tab does not change the theme, and all other tabs in the tabbar are no longer visible. you can still navigate with cmd+number though, and you will see all tabs when on a tab that was not focused, when the theme changed. but navigating back to the original tab will not show any tabs and also have the wrong theme on the tab. See this video:

https://github.com/user-attachments/assets/8d6cd313-0bb1-4ffb-a3ed-0770d755ab27

this happens for both macos-titlebar-style = tabs and transparent. using native does not have this issue.

uloco avatar Aug 07 '25 14:08 uloco

Fixed by #9090

mitchellh avatar Oct 10 '25 16:10 mitchellh