Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Panes should have editable titles #7290

Open
HunterMitchell opened this issue Aug 14, 2020 · 9 comments
Open

Panes should have editable titles #7290

HunterMitchell opened this issue Aug 14, 2020 · 9 comments
Assignees
Labels
Area-UserInterface Issues pertaining to the user interface of the Console or Terminal Help Wanted We encourage anyone to jump in on these. Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Product-Terminal The new Windows Terminal.
Milestone

Comments

@HunterMitchell
Copy link

Description of the new feature/enhancement

Having a title per tab is nice, but I have run into situations where I would much rather name each pane to help with multitasking. I have not seen this feature listed on #1000 and I feel like this can be of use for #7075. Below is Terminator on linux. Double-clicking the title allows editing and the title bar can be click-dragged to move panes around.
terminator

@HunterMitchell HunterMitchell added the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Aug 14, 2020
@ghost ghost added Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting Needs-Tag-Fix Doesn't match tag requirements labels Aug 14, 2020
@HunterMitchell
Copy link
Author

Currently working on a PR for this feature.

@zadjii-msft
Copy link
Member

I'm okay with this feature, as long as we make it disable-able with a setting ☺️

@zadjii-msft zadjii-msft added Area-UserInterface Issues pertaining to the user interface of the Console or Terminal Help Wanted We encourage anyone to jump in on these. Product-Terminal The new Windows Terminal. labels Aug 14, 2020
@ghost ghost removed the Needs-Tag-Fix Doesn't match tag requirements label Aug 14, 2020
@zadjii-msft zadjii-msft added this to the Terminal Backlog milestone Aug 14, 2020
@DHowett
Copy link
Member

DHowett commented Aug 15, 2020

This fits in with the vision I have of panes having titlebars, yeah. I'm yanking Triage 😄

@DHowett
Copy link
Member

DHowett commented Aug 15, 2020

Titlebars make good drag handles for reordering... and snapping... and everything. This almost blocks that. I'm surprised we didn't have a workitem for it!

@DHowett DHowett removed the Needs-Triage It's a new issue that the core contributor team needs to triage at the next triage meeting label Aug 15, 2020
@HunterMitchell
Copy link
Author

HunterMitchell commented Aug 17, 2020

I will be creating a draft PR soon, but had a few questions I wanted to run past you guys ( @zadjii-msft / @DHowett ). Since this pane titlebar is global, I assume it should be located in the GlobalAppSettings. Below is what I'm currently thinking these settings should look like.

{
    "paneTitlebar": {
        "show": true,
        "backgroundColor": "#FF0000",
        "foregroundColor": "#000000"
    }
}

On another note, most of my edits are in "Pane.h/Pane.cpp". Am I missing something, or is there not an easy way to get GlobalAppSettings? Maybe I missing something due to my lack of sleep lately 😁.

What I have so far (would like to see some border customization to match a theme down the road):
pane-titlebar

@zadjii-msft
Copy link
Member

Okay first off, that's amazing. Great work!

Secondly: I'd maybe hold off on the foreground/background color configuration until after #3327/#5772. Those are properties that IMO make more sense to be part of the visual "theme", which is a concept we're still working on. We're planning on throwing all sorts of visual customizations in there, including tab colors, titlebar colors, pane border colors, etc, so I think that's probably the best place for those settings to eventually live. I think for now we should probably just stick with some theme color to use as the pane titlebar BG. I'm really excited to see the possibility for colors in the (near) future though!

Third: Yea, the app settings are pretty hard to get at from Pane. You've gotta use const auto& settings = CascadiaSettings::GetCurrentAppSettings(); to get at the CascadiaSettings instance.

Forthly: I keep watching that gif and seeing new additional things you've already implemented in the pane title and I'm just constantly impressed. You've already got the context menu and double click renaming down. That's awesome. I'm excited.

@HunterMitchell
Copy link
Author

HunterMitchell commented Aug 18, 2020

I really appreciate the feedback and I'm pretty excited for theme support myself! It's been a hot minute since I've written some C++, so adding this feature I would like myself gave me the motivation to get back in the C++ realm.

I think for now we should probably just stick with some theme color to use as the pane titlebar BG.

Do you have a specific color in mind? You already know I have to support red, but I assume it needs to be some neutral color for now.

@zadjii-msft
Copy link
Member

zadjii-msft commented Aug 19, 2020

What if we started with the ChromeLow theme resource for now, and we'll let the design experts weigh in for the PR? 😉 That'll give us "a little darker" in dark theme, and "a little lighter" in light theme.

For the record, the titlebar uses ChromeDisabledHigh by default:

image

(from https://docs.microsoft.com/en-us/windows/uwp/design/controls-and-patterns/xaml-theme-resources)

Sound good?


EDIT Oh man I had an idea, what if we just used the same color as the tab background. (Refer to #7134, #7162) So if the control's "tabColor" changes, we should use that value as the pane color. So a profile's tabColor would apply to the pane titlebar. If there's no color set, then we'll use whatever value we pick as the default for the pane titlebars - this could either be ChromeLow or TabViewBackground(=ChromeDisabledHigh). But using the color picker to change the tab's color would set a value for the tab to use regardless of the pane titlebar color.

I'm rambling and brainstorming now.

@HunterMitchell
Copy link
Author

Sorry for the delay, I've been a bit busy. I went ahead and implemented the tab color change as requested, and it seems to work fine other than the fact I was unable to get it to change when the user uses the tab's color picker. I also have one small bug (or at least I hope it's small), that ill mention in the draft pull request ill be throwing up today. Maybe someone can give me some guidance on how to fix it.

I was also thinking a bit about the border for each pane and wanted to get your and other peoples opinion on using the pane's titlebar to indicate if a pane is focused or not. If you look at the image in my initial comment, terminator provides different colors (foreground / background) of the titlebar when active or not. In this case, the active pane has a white foreground and a darker background than the others. I am kinda wanting to get rid of the borders for a cleaner look (as seen in terminator), but I understand this might not be what the team has in mind for the UI. Of course, this would be an issue for user's who prefer not to use pane titlebars, but we might could only apply borders then? Just throwing out some ideas.

@ghost ghost added the In-PR This issue has a related PR label Aug 22, 2020
@ghost ghost removed the In-PR This issue has a related PR label Nov 18, 2020
@zadjii-msft zadjii-msft modified the milestones: Terminal Backlog, Backlog Jan 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-UserInterface Issues pertaining to the user interface of the Console or Terminal Help Wanted We encourage anyone to jump in on these. Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Product-Terminal The new Windows Terminal.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants