Feature Request: Setting to hide/remove close ("x") button from tabs #4659

Closed
opened 2026-01-30 23:53:14 +00:00 by claunia · 44 comments
Owner

Originally created by @dpaoliello on GitHub (Oct 25, 2019).

Add a setting to hide/remove close ("x") button from tabs

Issue Details:
Given that the size of tabs can change depending on each tab's title, attempting to use the mouse to change the current tab is fraught with danger: if a title suddenly changes, then you may end up hitting the close-tab button instead of switching.

Fix Details:
A possible solution to this is an option (disabled by default) to hide the close button for all tabs: users can still close tab with middle-click or Ctrl+W (or whatever hotkey they've set), but there is no risk of accidentally hitting the close button, with the added bonus of reducing the size of each tab.

NOTE: There are a number of other possible fixes for the problem I've described above (including "Restore closed tab" #960, "Confirmation prompt when closing a tab" #2976 and "Keep the width of tabs the same while the user is hovering over the tab bar"), but those are out-of-scope for this request.

Originally created by @dpaoliello on GitHub (Oct 25, 2019). Add a setting to hide/remove close ("x") button from tabs Issue Details: Given that the size of tabs can change depending on each tab's title, attempting to use the mouse to change the current tab is fraught with danger: if a title suddenly changes, then you may end up hitting the close-tab button instead of switching. Fix Details: A possible solution to this is an option (disabled by default) to hide the close button for all tabs: users can still close tab with middle-click or Ctrl+W (or whatever hotkey they've set), but there is no risk of accidentally hitting the close button, with the added bonus of reducing the size of each tab. NOTE: There are a number of other possible fixes for the problem I've described above (including "Restore closed tab" #960, "Confirmation prompt when closing a tab" #2976 and "Keep the width of tabs the same while the user is hovering over the tab bar"), but those are out-of-scope for this request.
Author
Owner

@zadjii-msft commented on GitHub (Oct 28, 2019):

Honestly I think that would just be a plain simple cool UI, even if all of the other issues referenced were fixed. I'm gonna tag this as a subset of #3327, and cc @cinnamon-msft, though this would probably be achievable without #3327.

@zadjii-msft commented on GitHub (Oct 28, 2019): Honestly I think that would just be a plain simple cool UI, even if all of the other issues referenced were fixed. I'm gonna tag this as a subset of #3327, and cc @cinnamon-msft, though this would probably be achievable without #3327.
Author
Owner

@austin-beer commented on GitHub (Jan 30, 2021):

I would love to see this feature implemented as well. Hopefully some progress can be made on this as part of #3327.

@austin-beer commented on GitHub (Jan 30, 2021): I would love to see this feature implemented as well. Hopefully some progress can be made on this as part of #3327.
Author
Owner

@ADTC commented on GitHub (Jul 17, 2021):

I accidentally clicked X on a tab when trying to switch to it, and it killed off an ng build --watch process that took me 5 minutes to load. There goes another 5 minutes!

Please, we need this, and we also need confirmation prompts for closing. It's not the same as accidentally closing a browser tab, for which you could click "Reopen closed tab" and just reload the page. The data loss implications are much greater here - you're killing off running foreground processes.

@ADTC commented on GitHub (Jul 17, 2021): I accidentally clicked X on a tab when trying to switch to it, and it killed off an `ng build --watch` process that took me 5 minutes to load. _There goes another 5 minutes!_ Please, we need this, and we also need confirmation prompts for closing. It's not the same as accidentally closing a browser tab, for which you could click "Reopen closed tab" and just reload the page. The data loss implications are much greater here - **you're killing off running foreground processes.**
Author
Owner

@lapo-luchini commented on GitHub (Oct 26, 2021):

Myself, I'd also like an option to only show "×" on hover (mainly to better use horizontal space when I have a lot of tabs)… which in parts is aligned with this issue (more customizability of UI) in part is exactly opposed (I guess it would make easier to close by mistake).
(But I'd like a completely missing "×" close button as well.)

@lapo-luchini commented on GitHub (Oct 26, 2021): Myself, I'd also like an option to only show "×" on hover (mainly to better use horizontal space when I have a lot of tabs)… which in parts is aligned with this issue (more customizability of UI) in part is exactly opposed (I guess it would make easier to close by mistake). (But I'd like a completely missing "×" close button as well.)
Author
Owner

@zohozer commented on GitHub (Mar 24, 2022):

Please add an option to remove this damn ("X") useless thing from the tabs that creates more problems than resolves. It is just enough and more intuitive to close a tab using the Middle Mouse Button and Ctrl+w shortcut without the fear to accidentally close an active process by pressing the "x" button.

@zohozer commented on GitHub (Mar 24, 2022): Please add an option to remove this damn ("X") useless thing from the tabs that creates more problems than resolves. It is just enough and more intuitive to close a tab using the Middle Mouse Button and Ctrl+w shortcut without the fear to accidentally close an active process by pressing the "x" button.
Author
Owner

@regnaio commented on GitHub (May 16, 2022):

Is this going to be implemented?

@regnaio commented on GitHub (May 16, 2022): Is this going to be implemented?
Author
Owner

@zadjii-msft commented on GitHub (May 16, 2022):

Probably at some point, sure. We've got the foundation for theming in PR over in #12992. Once that lands, I don't suspect it would be that hard to add a

"tab.showCloseButton": "always"|"hover"|"never"

setting to a theme. hover might be hard to implement, but I'd bet that never wouldn't be that hard.

@zadjii-msft commented on GitHub (May 16, 2022): Probably at some point, sure. We've got the foundation for theming in PR over in #12992. Once that lands, I don't suspect it would be that hard to add a ``` "tab.showCloseButton": "always"|"hover"|"never" ``` setting to a theme. `hover` might be hard to implement, but I'd bet that `never` wouldn't be that hard.
Author
Owner

@CraigDawson commented on GitHub (Jun 10, 2022):

I do this all the time too. Has it been implemented or is there a work-around?

@CraigDawson commented on GitHub (Jun 10, 2022): I do this all the time too. Has it been implemented or is there a work-around?
Author
Owner

@zadjii-msft commented on GitHub (Jun 10, 2022):

Has it been implemented

The issue is still open, so nope, it hasn't been implemented.

I'm not sure exactly how easy this would be to build on top of #12992 & #13178. always is obviously easy, and hover easily maps to TabViewCloseButtonOverlayMode.OnPointerOver. But never, that doesn't seem like an option. IsClosable might hide the close button, but that might also disable middle-click closing. We might be able to change the TabViewItem template, but that's quickly getting off the rails here. I don't think there's an open request on WinUI to add another value to that enum at the moment, either.

Other notes:

diff --git a/src/cascadia/TerminalApp/TabManagement.cpp b/src/cascadia/TerminalApp/TabManagement.cpp
index 47cfa70d7..51004e401 100644
--- a/src/cascadia/TerminalApp/TabManagement.cpp
+++ b/src/cascadia/TerminalApp/TabManagement.cpp
@@ -220,7 +220,12 @@ namespace winrt::TerminalApp::implementation
         });

         auto tabViewItem = newTabImpl->TabViewItem();
+^M
+        // tabViewItem.IsClosable(false);^M
         _tabView.TabItems().Append(tabViewItem);
+        _tabView.CloseButtonOverlayMode(MUX::Controls::TabViewCloseButtonOverlayMode::OnPointerOver);^M

         // Set this tab's icon to the icon from the user's profile
         if (const auto profile{ newTabImpl->GetFocusedProfile() })
@zadjii-msft commented on GitHub (Jun 10, 2022): > Has it been implemented The issue is still open, so nope, it hasn't been implemented. I'm not sure exactly how easy this would be to build on top of #12992 & #13178. `always` is obviously easy, and `hover` easily maps to [`TabViewCloseButtonOverlayMode.OnPointerOver`](https://docs.microsoft.com/en-us/windows/winui/api/microsoft.ui.xaml.controls.tabviewclosebuttonoverlaymode?view=winui-2.7&viewFallbackFrom=winui-2.2). But `never`, that doesn't seem like an option. [`IsClosable`](https://docs.microsoft.com/en-us/windows/winui/api/microsoft.ui.xaml.controls.tabviewitem.isclosable?view=winui-2.2#microsoft-ui-xaml-controls-tabviewitem-isclosable) might hide the close button, but that might also disable middle-click closing. We might be able to change the `TabViewItem` template, but that's quickly getting off the rails here. I don't think there's an open request on WinUI to add another value to that enum at the moment, either. Other notes: ```diff diff --git a/src/cascadia/TerminalApp/TabManagement.cpp b/src/cascadia/TerminalApp/TabManagement.cpp index 47cfa70d7..51004e401 100644 --- a/src/cascadia/TerminalApp/TabManagement.cpp +++ b/src/cascadia/TerminalApp/TabManagement.cpp @@ -220,7 +220,12 @@ namespace winrt::TerminalApp::implementation }); auto tabViewItem = newTabImpl->TabViewItem(); +^M + // tabViewItem.IsClosable(false);^M _tabView.TabItems().Append(tabViewItem); + _tabView.CloseButtonOverlayMode(MUX::Controls::TabViewCloseButtonOverlayMode::OnPointerOver);^M // Set this tab's icon to the icon from the user's profile if (const auto profile{ newTabImpl->GetFocusedProfile() }) ```
Author
Owner

@ADTC commented on GitHub (Jun 16, 2022):

Just give us a confirmation dialog, and we'd be mildly happier. 😄

@ADTC commented on GitHub (Jun 16, 2022): Just give us a confirmation dialog, and we'd be mildly happier. 😄
Author
Owner

@zadjii-msft commented on GitHub (Jun 16, 2022):

@ADTC That's tracked in #2976, #6549

@zadjii-msft commented on GitHub (Jun 16, 2022): @ADTC That's tracked in #2976, #6549
Author
Owner

@ADTC commented on GitHub (Jun 18, 2022):

...
+^M
+        // tabViewItem.IsClosable(false);^M
         _tabView.TabItems().Append(tabViewItem);
+        _tabView.CloseButtonOverlayMode(MUX::Controls::TabViewCloseButtonOverlayMode::OnPointerOver);^M
...

Seeing ^M there is bad news. You may want to ensure correct line endings in the file. LF is universally preferred, but seeing ^M could mean you have Windows line endings (CRLF) or Macintosh line endings (CR).

Git has an option to convert other line endings to Linux line endings upon committing, so even if a file is dirty in your local system, it will be clean in the commit. I suggest enabling it: git config --global core.autocrlf input (Reference)

@ADTC commented on GitHub (Jun 18, 2022): > ```diff > ... > +^M > + // tabViewItem.IsClosable(false);^M > _tabView.TabItems().Append(tabViewItem); > + _tabView.CloseButtonOverlayMode(MUX::Controls::TabViewCloseButtonOverlayMode::OnPointerOver);^M > ... > ``` Seeing `^M` there is bad news. You may want to ensure correct line endings in the file. `LF` is universally preferred, but seeing `^M` could mean you have Windows line endings (`CRLF`) or Macintosh line endings (`CR`). Git has an option to convert other line endings to Linux line endings upon committing, so even if a file is dirty in your local system, it will be clean in the commit. I suggest enabling it: `git config --global core.autocrlf input` ([Reference](https://git-scm.com/book/en/v2/Customizing-Git-Git-Configuration#_core_autocrlf))
Author
Owner

@DHowett commented on GitHub (Jun 18, 2022):

Eh, git does that every time it prepares a diff to render to the screen regardless of the core.autocrlf setting. I'm guessing Mike grabbed that from his scrollback, not from a patch file.

Some of this code flows back into Windows, so we prefer CRLF against git's best wishes. Yeah, it's awful.

Anyway, thanks for looking out for us! 😄

@DHowett commented on GitHub (Jun 18, 2022): Eh, git does that every time it prepares a diff to render to the screen regardless of the `core.autocrlf` setting. I'm guessing Mike grabbed that from his scrollback, not from a patch file. Some of this code flows back into Windows, so we prefer CRLF against git's best wishes. Yeah, it's awful. Anyway, thanks for looking out for us! 😄
Author
Owner

@zadjii-msft commented on GitHub (Jun 20, 2022):

Dustin's got it totally right, I was just quick using GH as a scratch pad there.

95790a5cce I think has the WIP. That should be able to get turned into a PR with minimal massaging

@zadjii-msft commented on GitHub (Jun 20, 2022): Dustin's got it totally right, I was just quick using GH as a scratch pad there. 95790a5cce85c776246a8eb19070f40d09d24bba I think has the WIP. That should be able to get turned into a PR with minimal massaging
Author
Owner

@mailinglists35 commented on GitHub (Aug 3, 2022):

  • "never": The close button is never visible. You can't close the tab with middle-click, but you can still use keyboard shortcuts to close the tab.

why is this? I expect to be able to middle click anywhere to close tab even if the close button is not visible

@mailinglists35 commented on GitHub (Aug 3, 2022): >* `"never"`: The close button is never visible. You can't close the tab with middle-click, but you can still use keyboard shortcuts to close the tab. why is this? I expect to be able to middle click anywhere to close tab even if the close button is not visible
Author
Owner

@ADTC commented on GitHub (Aug 3, 2022):

Will "never" still allow right-clicking and choosing close from the menu?

Can you have one more option, to have "active tab only"? Only the active tab shows the close button. If I need to close another tab with the close button I'd have to activate it first.

Honestly I don't see the point of "hover" since it doesn't solve the problem of accidentally clicking the close button, but now it makes it easier to do so, as close button would only appear when I hover but by then it's too late to realize there is one, just invisible.

@ADTC commented on GitHub (Aug 3, 2022): Will "never" still allow right-clicking and choosing close from the menu? Can you have one more option, to have "active tab only"? Only the active tab shows the close button. If I need to close another tab with the close button I'd have to activate it first. Honestly I don't see the point of "hover" since it doesn't solve the problem of accidentally clicking the close button, but now it makes it easier to do so, as close button would only appear when I hover but by then it's too late to realize there is one, just invisible.
Author
Owner

@zadjii-msft commented on GitHub (Aug 3, 2022):

why is this? I expect to be able to middle click anywhere to close tab

Alas, here we're limited by what the WinUI TabView gets us. IsClosable hides the X, but also disables middle click closing. There's no other easy way of changing that, short of wholesale forking the control.

Will "never" still allow right-clicking and choosing close from the menu?

Yep! Anything that we're providing on top of TabVeiw will still work, so renaming, the context menu, the keyboard shortcuts.

Can you have one more option, to have "active tab only"? Only the active tab shows the close button. If I need to close another tab with the close button I'd have to activate it first.

It's definitely no stretch of the imagination to add activeOnly to the enum values. That seems like a straightforward representation of what you want here. The trick is we're again limited by what TabView provides for us. We'd need another value added to TabViewCloseButtonOverlayMode in WinUI itself, and then we could leverage that.

If we can get some changes to TabView itself to support these things, I'd be more than happy to ingest them ☺️

@zadjii-msft commented on GitHub (Aug 3, 2022): > why is this? I expect to be able to middle click anywhere to close tab Alas, here we're limited by what the WinUI TabView gets us. `IsClosable` hides the <kbd>X</kbd>, but also disables middle click closing. There's no other easy way of changing that, short of wholesale forking the control. > Will "never" still allow right-clicking and choosing close from the menu? Yep! Anything that we're providing on top of TabVeiw will still work, so renaming, the context menu, the keyboard shortcuts. > Can you have one more option, to have "active tab only"? Only the active tab shows the close button. If I need to close another tab with the close button I'd have to activate it first. It's definitely no stretch of the imagination to add `activeOnly` to the enum values. That seems like a straightforward representation of what you want here. The trick is we're again limited by what TabView provides for us. We'd need another value added to [`TabViewCloseButtonOverlayMode`](https://docs.microsoft.com/en-us/windows/winui/api/microsoft.ui.xaml.controls.tabviewclosebuttonoverlaymode?view=winui-2.7&viewFallbackFrom=winui-2.2) in WinUI itself, and then we could leverage that. If we can get some changes to TabView itself to support these things, I'd be more than happy to ingest them ☺️
Author
Owner

@ADTC commented on GitHub (Aug 3, 2022):

@zadjii-msft thanks for your reply. I'm not clear on the last part. Surely it's trivial to add another enum but what I want to know if it's even possible on the current version of TabView to actualize what that enum would represent?

Is it possible to enable IsClosable on the active tab only, and disable it for all other tabs?

Anyway who controls the code for TabView? Is it here, or another project? Is there a GH repo for it where we can take our complaints to? 😄

@ADTC commented on GitHub (Aug 3, 2022): @zadjii-msft thanks for your reply. I'm not clear on the last part. Surely it's trivial to add another enum but what I want to know if it's even possible on the current version of `TabView` to actualize what that enum would represent? Is it possible to enable `IsClosable` on the active tab only, and disable it for all other tabs? Anyway who controls the code for `TabView`? Is it here, or another project? Is there a GH repo for it where we can take our complaints to? 😄
Author
Owner

@zadjii-msft commented on GitHub (Aug 3, 2022):

TabView is a part of WinUI, and that code is available over at https://github.com/microsoft/microsoft-ui-xaml/

I want to know if it's even possible on the current version of TabView to actualize what that enum would represent?

Hm.
a9c3b7724c/src/cascadia/TerminalApp/TerminalPage.cpp (L2740-L2772)

  • We could take that, turn that into a method.
  • Call that method every time the active tab changes...
  • ... or the set of tabs changes.
  • Get rid of all the calls to _updateTabCloseButton, cause that only updates a single tab.
  • Add logic in that method
    • Inside the loop, if the mode is ActiveOnly, and the tab is active, then IsClosable(true). else false
    • Outside the loop, set CloseButtonOverlayMode to Auto, probably a sensible default.

That sounds like it would work on paper. Wanna file a PR? 😄

@zadjii-msft commented on GitHub (Aug 3, 2022): `TabView` is a part of WinUI, and that code is available over at https://github.com/microsoft/microsoft-ui-xaml/ > I want to know if it's even possible on the current version of `TabView` to actualize what that enum would represent? Hm. https://github.com/microsoft/terminal/blob/a9c3b7724c05a0da059c4a0433ea446f8e19cbff/src/cascadia/TerminalApp/TerminalPage.cpp#L2740-L2772 * We could take that, turn that into a method. * Call that method every time the active tab changes... * ... or the set of tabs changes. * Get rid of all the calls to `_updateTabCloseButton`, cause that only updates a single tab. * Add logic in that method - Inside the loop, if the mode is `ActiveOnly`, and the tab is active, then `IsClosable(true)`. else `false` - Outside the loop, set `CloseButtonOverlayMode` to `Auto`, probably a sensible default. That sounds like it would work on paper. Wanna file a PR? 😄
Author
Owner

@ADTC commented on GitHub (Aug 3, 2022):

IDK maybe in the weekend. Haven't touched C++ in 10 years. 😄

Theory looks great though! Much love and thanks for your effort.

@ADTC commented on GitHub (Aug 3, 2022): IDK maybe in the weekend. Haven't touched C++ in 10 years. 😄 Theory looks great though! Much love and thanks for your effort.
Author
Owner

@mailinglists35 commented on GitHub (Aug 10, 2022):

Could someone please mention the link here if there ever an issue is filed for TabView/WinUI, so we can follow the progress?

I find it a usability regression to not be able to middle click only because there is no close button.

@mailinglists35 commented on GitHub (Aug 10, 2022): Could someone please mention the link here if there ever an issue is filed for TabView/WinUI, so we can follow the progress? I find it a usability regression to not be able to middle click only because there is no close button.
Author
Owner

@dezren39 commented on GitHub (Aug 31, 2022):

I use scaled windows with a big mouse cursor and many tabs, the inability to remove the close button means I usually avoid it entirely for fear of misclick. I'm confident in my middle-click and keyboard use, less so in single left click territory. It would be great if this could be resolved, sometimes I'm not careful and close very long-running processes by mistake. Even once is painful.

@dezren39 commented on GitHub (Aug 31, 2022): I use scaled windows with a big mouse cursor and many tabs, the inability to remove the close button means I usually avoid it entirely for fear of misclick. I'm confident in my middle-click and keyboard use, less so in single left click territory. It would be great if this could be resolved, sometimes I'm not careful and close very long-running processes by mistake. Even once is painful.
Author
Owner

@zadjii-msft commented on GitHub (Aug 31, 2022):

@dezren39 Then you might be interested in
image

@zadjii-msft commented on GitHub (Aug 31, 2022): @dezren39 Then you might be interested in ![image](https://user-images.githubusercontent.com/18356694/187568175-583f46f8-bc4c-4e17-8a6c-76341f51dcf0.png)
Author
Owner

@zohozer commented on GitHub (Aug 31, 2022):

Hi. Any working solution for this issue?

@zohozer commented on GitHub (Aug 31, 2022): Hi. Any working solution for this issue?
Author
Owner

@zadjii-msft commented on GitHub (Aug 31, 2022):

@zohozer Please read the thread. This has been fixed in main, and will be a part of Terminal 1.16.

@zadjii-msft commented on GitHub (Aug 31, 2022): @zohozer Please read the thread. This has been fixed in `main`, and will be a part of Terminal 1.16.
Author
Owner

@ghost commented on GitHub (Sep 13, 2022):

:tada:This issue was addressed in #13348, which has now been successfully released as Windows Terminal Preview v1.16.252.🎉

Handy links:

@ghost commented on GitHub (Sep 13, 2022): :tada:This issue was addressed in #13348, which has now been successfully released as `Windows Terminal Preview v1.16.252`.:tada: Handy links: * [Release Notes](https://github.com/microsoft/terminal/releases/tag/v1.16.252) * [Store Download](https://www.microsoft.com/store/apps/9n8g5rfz9xk3?cid=storebadge&ocid=badge)
Author
Owner

@mailinglists35 commented on GitHub (Sep 14, 2022):

how would this be enabled in the settings? I can't figure out from the release notes nor the commit. thanks

@mailinglists35 commented on GitHub (Sep 14, 2022): how would this be enabled in the settings? I can't figure out from the release notes nor the commit. thanks
Author
Owner

@zadjii-msft commented on GitHub (Sep 14, 2022):

Docs link

As an example from my test themes:

    "theme": "ninety eight",
    "themes":
    [
        {
            "name": "ninety eight",
            "tab":
            {
                "background": "#e0e3e4",
                "unfocusedBackground": "#c0c0c0",
                "showCloseButton": "never"
            },
            "tabRow":
            {
                "background": "#0000aa",
                "unfocusedBackground": "#87888f"
            },
            "window":
            {
                "applicationTheme": "light",
                "useMica": true
            }
        }
    ]
@zadjii-msft commented on GitHub (Sep 14, 2022): [Docs link](https://docs.microsoft.com/en-us/windows/terminal/customize-settings/themes#show-close-button) As an example from my test themes: ```json "theme": "ninety eight", "themes": [ { "name": "ninety eight", "tab": { "background": "#e0e3e4", "unfocusedBackground": "#c0c0c0", "showCloseButton": "never" }, "tabRow": { "background": "#0000aa", "unfocusedBackground": "#87888f" }, "window": { "applicationTheme": "light", "useMica": true } } ] ```
Author
Owner

@mailinglists35 commented on GitHub (Sep 14, 2022):

this is the themes contents in the default config file (well I changed from dark to light using the gui settings) :

    "theme": "light",
    "themes": [],

what is the minimal modification needed to enable showCloseButton on all default themes?

@mailinglists35 commented on GitHub (Sep 14, 2022): this is the themes contents in the default config file (well I changed from dark to light using the gui settings) : ```` "theme": "light", "themes": [], ```` what is the minimal modification needed to enable showCloseButton on all default themes?
Author
Owner

@mailinglists35 commented on GitHub (Sep 14, 2022):

would this be sufficient?

    "themes":
    [
        {
            "name": "light",
            "tab":
            {
                "showCloseButton": "never"
            },
        }
    ]
@mailinglists35 commented on GitHub (Sep 14, 2022): would this be sufficient? ```` "themes": [ { "name": "light", "tab": { "showCloseButton": "never" }, } ] ````
Author
Owner

@zadjii-msft commented on GitHub (Sep 14, 2022):

You'll need to change the name to something else, but yea, that'd do it. Then just change the theme property to whatever name you gave your theme.

@zadjii-msft commented on GitHub (Sep 14, 2022): You'll need to change the name to something else, but yea, that'd do it. Then just change the `theme` property to whatever name you gave your theme.
Author
Owner

@atc0005 commented on GitHub (Sep 14, 2022):

@zadjii-msft: You'll need to change the name to something else, but yea, that'd do it. Then just change the theme property to whatever name you gave your theme.

FWIW, I think I initially ran into the same problem as @mailinglists35.

I copied the example theme from the docs as-is and then added the "showCloseButton": "never" line. After looking at & testing your example from https://github.com/microsoft/terminal/issues/3335#issuecomment-1246658946 I realized that my attempt to create a custom theme (named dark) was conflicting with the default theme instead of overriding it.

It wasn't until I got things working that I went back to the docs and saw this:

This is the name of the theme. Names should be unique. The names dark, light, and system are reserved for the built-in default themes.

My attempt to use dark as the custom theme name is not allowed, but this is not emphasized by an error message. If you go strictly by the error message shown here:

image

The user might misunderstand that to mean that theme and themes[0].name should be set to one of the stock theme names.

I'm guessing that this will be fixed by a future schema update (regarding the warning message), but wanted to note it in case it helps someone else in the meantime.

@atc0005 commented on GitHub (Sep 14, 2022): > @zadjii-msft: You'll need to change the name to something else, but yea, that'd do it. Then just change the `theme` property to whatever name you gave your theme. FWIW, I think I initially ran into the same problem as @mailinglists35. I copied the example theme from the [docs](https://docs.microsoft.com/en-us/windows/terminal/customize-settings/themes) as-is and then added the `"showCloseButton": "never"` line. After looking at & testing your example from https://github.com/microsoft/terminal/issues/3335#issuecomment-1246658946 I realized that my attempt to create a custom theme (named `dark`) was conflicting with the default theme instead of overriding it. It wasn't until I got things working that I went back to the docs and saw this: > This is the name of the theme. Names should be unique. The names dark, light, and system are reserved for the built-in default themes. My attempt to use `dark` as the custom theme name is not allowed, but this is not emphasized by an error message. If you go strictly by the error message shown here: ![image](https://user-images.githubusercontent.com/36716992/190186831-c69c4de6-a3c9-445a-996a-24f3bb266943.png) The user might misunderstand that to mean that `theme` and `themes[0].name` should be set to one of the stock theme names. I'm guessing that this will be fixed by a future schema update (regarding the warning message), but wanted to note it in case it helps someone else in the meantime.
Author
Owner

@mailinglists35 commented on GitHub (Sep 14, 2022):

oh, so what is the way to go if I just want the light/dark theme plus this setting?

@mailinglists35 commented on GitHub (Sep 14, 2022): oh, so what is the way to go if I just want the light/dark theme plus this setting?
Author
Owner

@ALERTua commented on GitHub (Sep 14, 2022):

@atc0005 I just had to update my Windows Terminal Preview for this error to disappear.

    "themes":
    [
		{
			"name": "my_theme",
			"tab": {
				"showCloseButton": "never"
			},
			"window": {
				"applicationTheme": "system"
			}
		}
	],
    "theme": "my_theme"

This does hide the close button, but the middle mouse click stops closing the tab :\

even with

"pointerbindings": [
  {
  "device": "mouse",
  "event": "middleClick",
  "where": "tab",
  "command": "closeTab"
  }
]

what do

@ALERTua commented on GitHub (Sep 14, 2022): @atc0005 I just had to update my Windows Terminal Preview for this error to disappear. ``` "themes": [ { "name": "my_theme", "tab": { "showCloseButton": "never" }, "window": { "applicationTheme": "system" } } ], "theme": "my_theme" ``` This does hide the close button, but the middle mouse click stops closing the tab :\ even with ``` "pointerbindings": [ { "device": "mouse", "event": "middleClick", "where": "tab", "command": "closeTab" } ] ``` what do
Author
Owner

@zadjii-msft commented on GitHub (Sep 14, 2022):

what do

Read the thread: https://github.com/microsoft/terminal/issues/3335#issuecomment-1246890461.

IsClosable hides the X, but also disables middle click closing. There's no other easy way of changing that, short of wholesale forking the control.

Alas, that's just a limitation of TabView for the time being.

even with pointerbindings

That's... not a setting? Where'd you conjure that from?

oh, so what is the way to go if I just want the light/dark theme plus this setting?

  1. Copypasta 71fc4b1b0a/src/cascadia/TerminalSettingsModel/defaults.json (L297-L309) into your settings file.
  2. add the theme property you want. (in this case, "tab":{"showCloseButton": "never"})
  3. Set the name to foo.
  4. Change theme to "foo".
  5. Save the file.
@zadjii-msft commented on GitHub (Sep 14, 2022): > what do Read the thread: https://github.com/microsoft/terminal/issues/3335#issuecomment-1246890461. > `IsClosable` hides the X, but also disables middle click closing. There's no other easy way of changing that, short of wholesale forking the control. Alas, that's just a limitation of TabView for the time being. > even with `pointerbindings` That's... not a setting? Where'd you conjure that from? > oh, so what is the way to go if I just want the light/dark theme plus this setting? 1. Copypasta https://github.com/microsoft/terminal/blob/71fc4b1b0aee812bc7368c0b62a96018cb9fce86/src/cascadia/TerminalSettingsModel/defaults.json#L297-L309 into your settings file. 2. add the theme property you want. (in this case, `"tab":{"showCloseButton": "never"}`) 3. Set the name to `foo`. 4. Change `theme` to `"foo"`. 5. Save the file.
Author
Owner

@mailinglists35 commented on GitHub (Aug 24, 2023):

did I copy it wrong? I still see the close button.

image

{
    "$help": "https://aka.ms/terminal-documentation",
    "$schema": "https://aka.ms/terminal-profiles-schema",
    "actions": 
    [
        {
            "command": "find",
            "keys": "ctrl+shift+f"
        },
        {
            "command": "scrollUpPage",
            "keys": "shift+pgup"
        },
        {
            "command": "scrollDownPage",
            "keys": "shift+pgdn"
        },
        {
            "command": 
            {
                "action": "copy",
                "singleLine": false
            },
            "keys": "ctrl+c"
        },
        {
            "command": "paste",
            "keys": "ctrl+v"
        },
        {
            "command": 
            {
                "action": "splitPane",
                "split": "auto",
                "splitMode": "duplicate"
            },
            "keys": "alt+shift+d"
        }
    ],
    "copyFormatting": "none",
    "copyOnSelect": false,
    "defaultProfile": "{07b52e3e-de2c-5db4-bd2d-ba144ed6c273}",
    "disableAnimations": true,
    "newTabMenu": 
    [
        {
            "type": "remainingProfiles"
        }
    ],
    "profiles": 
    {
        "defaults": 
        {
            "adjustIndistinguishableColors": "always",
            "bellStyle": "taskbar",
            "colorScheme": "Tango Dark",
            "cursorShape": "filledBox",
            "font": 
            {
                "face": "Fantasque Sans Mono",
                "size": 16.0
            },
            "historySize": 99999
        },
        "list": 
        [
            {
                "colorScheme": "Tango Dark",
                "commandline": "%SystemRoot%\\System32\\WindowsPowerShell\\v1.0\\powershell.exe",
                "guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}",
                "hidden": false,
                "name": "Windows PowerShell"
            },
            {
                "colorScheme": "Tango Dark",
                "commandline": "%SystemRoot%\\System32\\cmd.exe",
                "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}",
                "hidden": false,
                "name": "Command Prompt",
                "startingDirectory": "c:\\"
            },
            {
                "colorScheme": "Tango Dark",
                "guid": "{07b52e3e-de2c-5db4-bd2d-ba144ed6c273}",
                "hidden": false,
                "name": "Ubuntu-work",
                "source": "Windows.Terminal.Wsl"
            },
            {
                "guid": "{b453ae62-4e3d-5e58-b989-0a998ec441b8}",
                "hidden": false,
                "name": "Azure Cloud Shell",
                "source": "Windows.Terminal.Azure"
            },
            {
                "guid": "{51855cb2-8cce-5362-8f54-464b92b32386}",
                "hidden": false,
                "name": "Ubuntu",
                "source": "CanonicalGroupLimited.Ubuntu_79rhkp1fndgsc"
            },
            {
                "guid": "{8c701c6d-1341-546d-84ae-1a1fb3a809ed}",
                "hidden": false,
                "name": "Ubuntu (Preview)",
                "source": "CanonicalGroupLimited.UbuntuPreview_79rhkp1fndgsc"
            },
            {
                "guid": "{491fa895-2dca-5d90-ba62-3da4b59cffe2}",
                "hidden": true,
                "name": "Ubuntu-Preview",
                "source": "Windows.Terminal.Wsl"
            },
            {
                "guid": "{2c4de342-38b7-51cf-b940-2309a097f518}",
                "hidden": true,
                "name": "Ubuntu",
                "source": "Windows.Terminal.Wsl"
            },
            {
                "guid": "{17bf3de4-5353-5709-bcf9-835bd952a95e}",
                "hidden": true,
                "name": "Ubuntu-22.04",
                "source": "Windows.Terminal.Wsl"
            },
            {
                "guid": "{d7b20cea-47a9-518c-95a4-c8bd91e2e1c6}",
                "hidden": false,
                "name": "Ubuntu 22.04.2 LTS",
                "source": "CanonicalGroupLimited.Ubuntu22.04LTS_79rhkp1fndgsc"
            }
        ]
    },
    "schemes": 
    [
        {
            "background": "#0C0C0C",
            "black": "#0C0C0C",
            "blue": "#0037DA",
            "brightBlack": "#767676",
            "brightBlue": "#3B78FF",
            "brightCyan": "#61D6D6",
            "brightGreen": "#16C60C",
            "brightPurple": "#B4009E",
            "brightRed": "#E74856",
            "brightWhite": "#F2F2F2",
            "brightYellow": "#F9F1A5",
            "cursorColor": "#FFFFFF",
            "cyan": "#3A96DD",
            "foreground": "#CCCCCC",
            "green": "#13A10E",
            "name": "Campbell",
            "purple": "#881798",
            "red": "#C50F1F",
            "selectionBackground": "#FFFFFF",
            "white": "#CCCCCC",
            "yellow": "#C19C00"
        },
        {
            "background": "#012456",
            "black": "#0C0C0C",
            "blue": "#0037DA",
            "brightBlack": "#767676",
            "brightBlue": "#3B78FF",
            "brightCyan": "#61D6D6",
            "brightGreen": "#16C60C",
            "brightPurple": "#B4009E",
            "brightRed": "#E74856",
            "brightWhite": "#F2F2F2",
            "brightYellow": "#F9F1A5",
            "cursorColor": "#FFFFFF",
            "cyan": "#3A96DD",
            "foreground": "#CCCCCC",
            "green": "#13A10E",
            "name": "Campbell Powershell",
            "purple": "#881798",
            "red": "#C50F1F",
            "selectionBackground": "#FFFFFF",
            "white": "#CCCCCC",
            "yellow": "#C19C00"
        },
        {
            "background": "#282C34",
            "black": "#282C34",
            "blue": "#61AFEF",
            "brightBlack": "#5A6374",
            "brightBlue": "#61AFEF",
            "brightCyan": "#56B6C2",
            "brightGreen": "#98C379",
            "brightPurple": "#C678DD",
            "brightRed": "#E06C75",
            "brightWhite": "#DCDFE4",
            "brightYellow": "#E5C07B",
            "cursorColor": "#FFFFFF",
            "cyan": "#56B6C2",
            "foreground": "#DCDFE4",
            "green": "#98C379",
            "name": "One Half Dark",
            "purple": "#C678DD",
            "red": "#E06C75",
            "selectionBackground": "#FFFFFF",
            "white": "#DCDFE4",
            "yellow": "#E5C07B"
        },
        {
            "background": "#FAFAFA",
            "black": "#383A42",
            "blue": "#0184BC",
            "brightBlack": "#4F525D",
            "brightBlue": "#61AFEF",
            "brightCyan": "#56B5C1",
            "brightGreen": "#98C379",
            "brightPurple": "#C577DD",
            "brightRed": "#DF6C75",
            "brightWhite": "#FFFFFF",
            "brightYellow": "#E4C07A",
            "cursorColor": "#4F525D",
            "cyan": "#0997B3",
            "foreground": "#383A42",
            "green": "#50A14F",
            "name": "One Half Light",
            "purple": "#A626A4",
            "red": "#E45649",
            "selectionBackground": "#FFFFFF",
            "white": "#FAFAFA",
            "yellow": "#C18301"
        },
        {
            "background": "#002B36",
            "black": "#002B36",
            "blue": "#268BD2",
            "brightBlack": "#073642",
            "brightBlue": "#839496",
            "brightCyan": "#93A1A1",
            "brightGreen": "#586E75",
            "brightPurple": "#6C71C4",
            "brightRed": "#CB4B16",
            "brightWhite": "#FDF6E3",
            "brightYellow": "#657B83",
            "cursorColor": "#FFFFFF",
            "cyan": "#2AA198",
            "foreground": "#839496",
            "green": "#859900",
            "name": "Solarized Dark",
            "purple": "#D33682",
            "red": "#DC322F",
            "selectionBackground": "#FFFFFF",
            "white": "#EEE8D5",
            "yellow": "#B58900"
        },
        {
            "background": "#FDF6E3",
            "black": "#002B36",
            "blue": "#268BD2",
            "brightBlack": "#073642",
            "brightBlue": "#839496",
            "brightCyan": "#93A1A1",
            "brightGreen": "#586E75",
            "brightPurple": "#6C71C4",
            "brightRed": "#CB4B16",
            "brightWhite": "#FDF6E3",
            "brightYellow": "#657B83",
            "cursorColor": "#002B36",
            "cyan": "#2AA198",
            "foreground": "#657B83",
            "green": "#859900",
            "name": "Solarized Light",
            "purple": "#D33682",
            "red": "#DC322F",
            "selectionBackground": "#FFFFFF",
            "white": "#EEE8D5",
            "yellow": "#B58900"
        },
        {
            "background": "#000000",
            "black": "#000000",
            "blue": "#3465A4",
            "brightBlack": "#555753",
            "brightBlue": "#729FCF",
            "brightCyan": "#34E2E2",
            "brightGreen": "#8AE234",
            "brightPurple": "#AD7FA8",
            "brightRed": "#EF2929",
            "brightWhite": "#EEEEEC",
            "brightYellow": "#FCE94F",
            "cursorColor": "#FFFFFF",
            "cyan": "#06989A",
            "foreground": "#D3D7CF",
            "green": "#4E9A06",
            "name": "Tango Dark",
            "purple": "#75507B",
            "red": "#CC0000",
            "selectionBackground": "#FFFFFF",
            "white": "#D3D7CF",
            "yellow": "#C4A000"
        },
        {
            "background": "#FFFFFF",
            "black": "#000000",
            "blue": "#3465A4",
            "brightBlack": "#555753",
            "brightBlue": "#729FCF",
            "brightCyan": "#34E2E2",
            "brightGreen": "#8AE234",
            "brightPurple": "#AD7FA8",
            "brightRed": "#EF2929",
            "brightWhite": "#EEEEEC",
            "brightYellow": "#FCE94F",
            "cursorColor": "#000000",
            "cyan": "#06989A",
            "foreground": "#555753",
            "green": "#4E9A06",
            "name": "Tango Light",
            "purple": "#75507B",
            "red": "#CC0000",
            "selectionBackground": "#FFFFFF",
            "white": "#D3D7CF",
            "yellow": "#C4A000"
        },
        {
            "background": "#300A24",
            "black": "#171421",
            "blue": "#0037DA",
            "brightBlack": "#767676",
            "brightBlue": "#08458F",
            "brightCyan": "#2C9FB3",
            "brightGreen": "#26A269",
            "brightPurple": "#A347BA",
            "brightRed": "#C01C28",
            "brightWhite": "#F2F2F2",
            "brightYellow": "#A2734C",
            "cursorColor": "#FFFFFF",
            "cyan": "#3A96DD",
            "foreground": "#FFFFFF",
            "green": "#26A269",
            "name": "Ubuntu-22.04-ColorScheme",
            "purple": "#881798",
            "red": "#C21A23",
            "selectionBackground": "#FFFFFF",
            "white": "#CCCCCC",
            "yellow": "#A2734C"
        },
        {
            "background": "#300A24",
            "black": "#171421",
            "blue": "#0037DA",
            "brightBlack": "#767676",
            "brightBlue": "#08458F",
            "brightCyan": "#2C9FB3",
            "brightGreen": "#26A269",
            "brightPurple": "#A347BA",
            "brightRed": "#C01C28",
            "brightWhite": "#F2F2F2",
            "brightYellow": "#A2734C",
            "cursorColor": "#FFFFFF",
            "cyan": "#3A96DD",
            "foreground": "#FFFFFF",
            "green": "#26A269",
            "name": "Ubuntu-ColorScheme",
            "purple": "#881798",
            "red": "#C21A23",
            "selectionBackground": "#FFFFFF",
            "white": "#CCCCCC",
            "yellow": "#A2734C"
        },
        {
            "background": "#300A24",
            "black": "#171421",
            "blue": "#0037DA",
            "brightBlack": "#767676",
            "brightBlue": "#08458F",
            "brightCyan": "#2C9FB3",
            "brightGreen": "#26A269",
            "brightPurple": "#A347BA",
            "brightRed": "#C01C28",
            "brightWhite": "#F2F2F2",
            "brightYellow": "#A2734C",
            "cursorColor": "#FFFFFF",
            "cyan": "#3A96DD",
            "foreground": "#FFFFFF",
            "green": "#26A269",
            "name": "Ubuntu-Preview-ColorScheme",
            "purple": "#881798",
            "red": "#C21A23",
            "selectionBackground": "#FFFFFF",
            "white": "#CCCCCC",
            "yellow": "#A2734C"
        },
        {
            "background": "#000000",
            "black": "#000000",
            "blue": "#000080",
            "brightBlack": "#808080",
            "brightBlue": "#0000FF",
            "brightCyan": "#00FFFF",
            "brightGreen": "#00FF00",
            "brightPurple": "#FF00FF",
            "brightRed": "#FF0000",
            "brightWhite": "#FFFFFF",
            "brightYellow": "#FFFF00",
            "cursorColor": "#FFFFFF",
            "cyan": "#008080",
            "foreground": "#C0C0C0",
            "green": "#008000",
            "name": "Vintage",
            "purple": "#800080",
            "red": "#800000",
            "selectionBackground": "#FFFFFF",
            "white": "#C0C0C0",
            "yellow": "#808000"
        }
    ],
    "theme": "dark",
    "themes": [
    { 
     "name": "dark", 
     "window": { 
         "applicationTheme": "dark" 
     }, 
     "tab": { 
         "background": "terminalBackground", 
         "unfocusedBackground": "#00000000" 
     }, 
     "tabRow": { 
         "unfocusedBackground": "#333333FF" 
     },
     "tab": {"showCloseButton": "never"} 
     }
],
    "wordDelimiters": " \\()\"',;<>~!#$%^&*|+[]{}~?\u2502"
}
@mailinglists35 commented on GitHub (Aug 24, 2023): did I copy it wrong? I still see the close button. ![image](https://github.com/microsoft/terminal/assets/2054302/77df9353-ec84-4090-a17c-707db4a84adb) ```` { "$help": "https://aka.ms/terminal-documentation", "$schema": "https://aka.ms/terminal-profiles-schema", "actions": [ { "command": "find", "keys": "ctrl+shift+f" }, { "command": "scrollUpPage", "keys": "shift+pgup" }, { "command": "scrollDownPage", "keys": "shift+pgdn" }, { "command": { "action": "copy", "singleLine": false }, "keys": "ctrl+c" }, { "command": "paste", "keys": "ctrl+v" }, { "command": { "action": "splitPane", "split": "auto", "splitMode": "duplicate" }, "keys": "alt+shift+d" } ], "copyFormatting": "none", "copyOnSelect": false, "defaultProfile": "{07b52e3e-de2c-5db4-bd2d-ba144ed6c273}", "disableAnimations": true, "newTabMenu": [ { "type": "remainingProfiles" } ], "profiles": { "defaults": { "adjustIndistinguishableColors": "always", "bellStyle": "taskbar", "colorScheme": "Tango Dark", "cursorShape": "filledBox", "font": { "face": "Fantasque Sans Mono", "size": 16.0 }, "historySize": 99999 }, "list": [ { "colorScheme": "Tango Dark", "commandline": "%SystemRoot%\\System32\\WindowsPowerShell\\v1.0\\powershell.exe", "guid": "{61c54bbd-c2c6-5271-96e7-009a87ff44bf}", "hidden": false, "name": "Windows PowerShell" }, { "colorScheme": "Tango Dark", "commandline": "%SystemRoot%\\System32\\cmd.exe", "guid": "{0caa0dad-35be-5f56-a8ff-afceeeaa6101}", "hidden": false, "name": "Command Prompt", "startingDirectory": "c:\\" }, { "colorScheme": "Tango Dark", "guid": "{07b52e3e-de2c-5db4-bd2d-ba144ed6c273}", "hidden": false, "name": "Ubuntu-work", "source": "Windows.Terminal.Wsl" }, { "guid": "{b453ae62-4e3d-5e58-b989-0a998ec441b8}", "hidden": false, "name": "Azure Cloud Shell", "source": "Windows.Terminal.Azure" }, { "guid": "{51855cb2-8cce-5362-8f54-464b92b32386}", "hidden": false, "name": "Ubuntu", "source": "CanonicalGroupLimited.Ubuntu_79rhkp1fndgsc" }, { "guid": "{8c701c6d-1341-546d-84ae-1a1fb3a809ed}", "hidden": false, "name": "Ubuntu (Preview)", "source": "CanonicalGroupLimited.UbuntuPreview_79rhkp1fndgsc" }, { "guid": "{491fa895-2dca-5d90-ba62-3da4b59cffe2}", "hidden": true, "name": "Ubuntu-Preview", "source": "Windows.Terminal.Wsl" }, { "guid": "{2c4de342-38b7-51cf-b940-2309a097f518}", "hidden": true, "name": "Ubuntu", "source": "Windows.Terminal.Wsl" }, { "guid": "{17bf3de4-5353-5709-bcf9-835bd952a95e}", "hidden": true, "name": "Ubuntu-22.04", "source": "Windows.Terminal.Wsl" }, { "guid": "{d7b20cea-47a9-518c-95a4-c8bd91e2e1c6}", "hidden": false, "name": "Ubuntu 22.04.2 LTS", "source": "CanonicalGroupLimited.Ubuntu22.04LTS_79rhkp1fndgsc" } ] }, "schemes": [ { "background": "#0C0C0C", "black": "#0C0C0C", "blue": "#0037DA", "brightBlack": "#767676", "brightBlue": "#3B78FF", "brightCyan": "#61D6D6", "brightGreen": "#16C60C", "brightPurple": "#B4009E", "brightRed": "#E74856", "brightWhite": "#F2F2F2", "brightYellow": "#F9F1A5", "cursorColor": "#FFFFFF", "cyan": "#3A96DD", "foreground": "#CCCCCC", "green": "#13A10E", "name": "Campbell", "purple": "#881798", "red": "#C50F1F", "selectionBackground": "#FFFFFF", "white": "#CCCCCC", "yellow": "#C19C00" }, { "background": "#012456", "black": "#0C0C0C", "blue": "#0037DA", "brightBlack": "#767676", "brightBlue": "#3B78FF", "brightCyan": "#61D6D6", "brightGreen": "#16C60C", "brightPurple": "#B4009E", "brightRed": "#E74856", "brightWhite": "#F2F2F2", "brightYellow": "#F9F1A5", "cursorColor": "#FFFFFF", "cyan": "#3A96DD", "foreground": "#CCCCCC", "green": "#13A10E", "name": "Campbell Powershell", "purple": "#881798", "red": "#C50F1F", "selectionBackground": "#FFFFFF", "white": "#CCCCCC", "yellow": "#C19C00" }, { "background": "#282C34", "black": "#282C34", "blue": "#61AFEF", "brightBlack": "#5A6374", "brightBlue": "#61AFEF", "brightCyan": "#56B6C2", "brightGreen": "#98C379", "brightPurple": "#C678DD", "brightRed": "#E06C75", "brightWhite": "#DCDFE4", "brightYellow": "#E5C07B", "cursorColor": "#FFFFFF", "cyan": "#56B6C2", "foreground": "#DCDFE4", "green": "#98C379", "name": "One Half Dark", "purple": "#C678DD", "red": "#E06C75", "selectionBackground": "#FFFFFF", "white": "#DCDFE4", "yellow": "#E5C07B" }, { "background": "#FAFAFA", "black": "#383A42", "blue": "#0184BC", "brightBlack": "#4F525D", "brightBlue": "#61AFEF", "brightCyan": "#56B5C1", "brightGreen": "#98C379", "brightPurple": "#C577DD", "brightRed": "#DF6C75", "brightWhite": "#FFFFFF", "brightYellow": "#E4C07A", "cursorColor": "#4F525D", "cyan": "#0997B3", "foreground": "#383A42", "green": "#50A14F", "name": "One Half Light", "purple": "#A626A4", "red": "#E45649", "selectionBackground": "#FFFFFF", "white": "#FAFAFA", "yellow": "#C18301" }, { "background": "#002B36", "black": "#002B36", "blue": "#268BD2", "brightBlack": "#073642", "brightBlue": "#839496", "brightCyan": "#93A1A1", "brightGreen": "#586E75", "brightPurple": "#6C71C4", "brightRed": "#CB4B16", "brightWhite": "#FDF6E3", "brightYellow": "#657B83", "cursorColor": "#FFFFFF", "cyan": "#2AA198", "foreground": "#839496", "green": "#859900", "name": "Solarized Dark", "purple": "#D33682", "red": "#DC322F", "selectionBackground": "#FFFFFF", "white": "#EEE8D5", "yellow": "#B58900" }, { "background": "#FDF6E3", "black": "#002B36", "blue": "#268BD2", "brightBlack": "#073642", "brightBlue": "#839496", "brightCyan": "#93A1A1", "brightGreen": "#586E75", "brightPurple": "#6C71C4", "brightRed": "#CB4B16", "brightWhite": "#FDF6E3", "brightYellow": "#657B83", "cursorColor": "#002B36", "cyan": "#2AA198", "foreground": "#657B83", "green": "#859900", "name": "Solarized Light", "purple": "#D33682", "red": "#DC322F", "selectionBackground": "#FFFFFF", "white": "#EEE8D5", "yellow": "#B58900" }, { "background": "#000000", "black": "#000000", "blue": "#3465A4", "brightBlack": "#555753", "brightBlue": "#729FCF", "brightCyan": "#34E2E2", "brightGreen": "#8AE234", "brightPurple": "#AD7FA8", "brightRed": "#EF2929", "brightWhite": "#EEEEEC", "brightYellow": "#FCE94F", "cursorColor": "#FFFFFF", "cyan": "#06989A", "foreground": "#D3D7CF", "green": "#4E9A06", "name": "Tango Dark", "purple": "#75507B", "red": "#CC0000", "selectionBackground": "#FFFFFF", "white": "#D3D7CF", "yellow": "#C4A000" }, { "background": "#FFFFFF", "black": "#000000", "blue": "#3465A4", "brightBlack": "#555753", "brightBlue": "#729FCF", "brightCyan": "#34E2E2", "brightGreen": "#8AE234", "brightPurple": "#AD7FA8", "brightRed": "#EF2929", "brightWhite": "#EEEEEC", "brightYellow": "#FCE94F", "cursorColor": "#000000", "cyan": "#06989A", "foreground": "#555753", "green": "#4E9A06", "name": "Tango Light", "purple": "#75507B", "red": "#CC0000", "selectionBackground": "#FFFFFF", "white": "#D3D7CF", "yellow": "#C4A000" }, { "background": "#300A24", "black": "#171421", "blue": "#0037DA", "brightBlack": "#767676", "brightBlue": "#08458F", "brightCyan": "#2C9FB3", "brightGreen": "#26A269", "brightPurple": "#A347BA", "brightRed": "#C01C28", "brightWhite": "#F2F2F2", "brightYellow": "#A2734C", "cursorColor": "#FFFFFF", "cyan": "#3A96DD", "foreground": "#FFFFFF", "green": "#26A269", "name": "Ubuntu-22.04-ColorScheme", "purple": "#881798", "red": "#C21A23", "selectionBackground": "#FFFFFF", "white": "#CCCCCC", "yellow": "#A2734C" }, { "background": "#300A24", "black": "#171421", "blue": "#0037DA", "brightBlack": "#767676", "brightBlue": "#08458F", "brightCyan": "#2C9FB3", "brightGreen": "#26A269", "brightPurple": "#A347BA", "brightRed": "#C01C28", "brightWhite": "#F2F2F2", "brightYellow": "#A2734C", "cursorColor": "#FFFFFF", "cyan": "#3A96DD", "foreground": "#FFFFFF", "green": "#26A269", "name": "Ubuntu-ColorScheme", "purple": "#881798", "red": "#C21A23", "selectionBackground": "#FFFFFF", "white": "#CCCCCC", "yellow": "#A2734C" }, { "background": "#300A24", "black": "#171421", "blue": "#0037DA", "brightBlack": "#767676", "brightBlue": "#08458F", "brightCyan": "#2C9FB3", "brightGreen": "#26A269", "brightPurple": "#A347BA", "brightRed": "#C01C28", "brightWhite": "#F2F2F2", "brightYellow": "#A2734C", "cursorColor": "#FFFFFF", "cyan": "#3A96DD", "foreground": "#FFFFFF", "green": "#26A269", "name": "Ubuntu-Preview-ColorScheme", "purple": "#881798", "red": "#C21A23", "selectionBackground": "#FFFFFF", "white": "#CCCCCC", "yellow": "#A2734C" }, { "background": "#000000", "black": "#000000", "blue": "#000080", "brightBlack": "#808080", "brightBlue": "#0000FF", "brightCyan": "#00FFFF", "brightGreen": "#00FF00", "brightPurple": "#FF00FF", "brightRed": "#FF0000", "brightWhite": "#FFFFFF", "brightYellow": "#FFFF00", "cursorColor": "#FFFFFF", "cyan": "#008080", "foreground": "#C0C0C0", "green": "#008000", "name": "Vintage", "purple": "#800080", "red": "#800000", "selectionBackground": "#FFFFFF", "white": "#C0C0C0", "yellow": "#808000" } ], "theme": "dark", "themes": [ { "name": "dark", "window": { "applicationTheme": "dark" }, "tab": { "background": "terminalBackground", "unfocusedBackground": "#00000000" }, "tabRow": { "unfocusedBackground": "#333333FF" }, "tab": {"showCloseButton": "never"} } ], "wordDelimiters": " \\()\"',;<>~!#$%^&*|+[]{}~?\u2502" } ````
Author
Owner

@mailinglists35 commented on GitHub (Aug 24, 2023):

before it was simply

"themes": []
@mailinglists35 commented on GitHub (Aug 24, 2023): before it was simply ```` "themes": [] ````
Author
Owner

@zadjii-msft commented on GitHub (Aug 24, 2023):

Ah, you missed a crucial pair of steps:

  1. Set the name to "foo".
  2. Change theme to "foo"

Themes don't let you directly override built-in theme names (dark, light, system)

@zadjii-msft commented on GitHub (Aug 24, 2023): Ah, you missed a crucial pair of steps: > 3. Set the `name` to `"foo"`. > 4. Change `theme` to `"foo"` Themes don't let you directly override built-in theme names (`dark`, `light`, `system`)
Author
Owner

@mailinglists35 commented on GitHub (Aug 24, 2023):

a w e s o m e

I am finally worry-free clicking anywhere in the tab bar!

thank you

@mailinglists35 commented on GitHub (Aug 24, 2023): a w e s o m e I am finally worry-free clicking anywhere in the tab bar! thank you
Author
Owner

@lapo-luchini commented on GitHub (Aug 29, 2023):

Even better! 🎉
"showCloseButton": "hover"

@lapo-luchini commented on GitHub (Aug 29, 2023): Even better! 🎉 `"showCloseButton": "hover"`
Author
Owner

@mreymann commented on GitHub (Aug 30, 2023):

It would be great if this feature could be activated by just an option in the settings. Is this planned?

@mreymann commented on GitHub (Aug 30, 2023): It would be great if this feature could be activated by just an option in the settings. Is this planned?
Author
Owner

@mreymann commented on GitHub (Jan 12, 2024):

Ok, my annoyance level grew so much that I eventually edited my settings.json accordingly, using "showCloseButton": "activeOnly". I'll see if that works out. Still would prefer a simple selection in the options.

@mreymann commented on GitHub (Jan 12, 2024): Ok, my annoyance level grew so much that I eventually edited my settings.json accordingly, using "showCloseButton": "activeOnly". I'll see if that works out. Still would prefer a simple selection in the options.
Author
Owner

@2x2xplz commented on GitHub (Jan 23, 2024):

The "close tab" area is significantly larger than just the visible X and takes up more than half of a minimized tab:
image

It's way too easy to accidentally click "close" even when you give yourself extra margin, especially with no close tab confirmation. Please, as @mreymann suggested, just make this a simple setting to change (without needing to create a whole new theme) -- and preferably, add a confirmation the first few times for new Terminal users.

Sticking with ConEmu in the meantime.

@2x2xplz commented on GitHub (Jan 23, 2024): The "close tab" area is significantly larger than just the visible `X` and takes up more than half of a minimized tab: ![image](https://github.com/microsoft/terminal/assets/16587079/97d837ed-2fd5-4fdc-ad93-92ace39f1d3d) It's way too easy to accidentally click "close" even when you give yourself extra margin, especially with no close tab confirmation. Please, as @mreymann suggested, just make this a simple setting to change (without needing to create a whole new theme) -- and preferably, add a confirmation the first few times for new `Terminal` users. Sticking with ConEmu in the meantime.
Author
Owner

@maggu commented on GitHub (Aug 12, 2024):

Ok, my annoyance level grew so much that I eventually edited my settings.json accordingly, using "showCloseButton": "activeOnly". I'll see if that works out. Still would prefer a simple selection in the options.

Yes, activeOnly (#13672) was a great addition, and for me really the obvious value to set. Exactly like tabs in a browser (when they're packed tightly enough; seems to work the same way in Edge, Chrome and Firefox by the way). I've used Windows Terminal daily since it was in Preview and this removed my last source of irritation. Although never did prevent accidental closing of tabs, it was also somewhat annoying it it's own way.

This thread has been really useful in figuring out how to write the JSON. Thanks. I went with the minimal approach as well, just to get the feature working. Exposing it in the settings UI as well would be a welcome addition.

@maggu commented on GitHub (Aug 12, 2024): > Ok, my annoyance level grew so much that I eventually edited my settings.json accordingly, using "showCloseButton": "activeOnly". I'll see if that works out. Still would prefer a simple selection in the options. Yes, `activeOnly` (#13672) was a great addition, and for me really the obvious value to set. Exactly like tabs in a browser (when they're packed tightly enough; seems to work the same way in Edge, Chrome and Firefox by the way). I've used Windows Terminal daily since it was in Preview and this removed my last source of irritation. Although `never` did prevent accidental closing of tabs, it was also somewhat annoying it it's own way. This thread has been really useful in figuring out how to write the JSON. Thanks. I went with the minimal approach as well, just to get the feature working. Exposing it in the settings UI as well would be a welcome addition.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#4659