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

Limit width of Tab to a fixed maximum or otherwise (maybe text length) #15211

Closed
thojaw opened this issue Apr 20, 2023 · 2 comments
Closed

Limit width of Tab to a fixed maximum or otherwise (maybe text length) #15211

thojaw opened this issue Apr 20, 2023 · 2 comments
Labels
Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.

Comments

@thojaw
Copy link

thojaw commented Apr 20, 2023

Limit width of Tab to a fixed maximum or otherwise (maybe text length)

The Windows Terminal Tabs might grow too wide especially when using "titleLength" for Tab width mode. For example, sometimes when I run a Console App from Visual Studio in Windows Terminal, it will render the executables path as the Title, but there could be other reasons.

With a long title, in the screenshot, my 3rd tab already breaks and tab scrolling is activated. I run into this situation many times and it keeps me from using the "titleLength" tab width mode.

scr

Long display proposal

Maybe the max. tab Title text length could be restricted in the configuration, e.g. to 40 characters. Split the text in half, remove overhead, put an Ellipsis in the middle.

scr2

Javascript Semi-Code

const tabText = 'this title needs to be truncated';
const regex = /(^.{12}).*(.{12}$)/; // the 12 is dynamic, e.g. for max length of 25

console.log(tabText.replace(regex, '$1…$2')); // "this title n…be truncated"
@thojaw thojaw added the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Apr 20, 2023
@microsoft-github-policy-service microsoft-github-policy-service bot 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 Apr 20, 2023
@zadjii-msft
Copy link
Member

Thanks for the suggestion! This is actually already being tracked by another issue on our repo - please refer to #597 for more discussion.

/dup #597 (boy that's an old one)

@zadjii-msft zadjii-msft closed this as not planned Won't fix, can't repro, duplicate, stale Apr 20, 2023
@microsoft-github-policy-service
Copy link
Contributor

Hi! We've identified this issue as a duplicate of another one that already exists on this Issue Tracker. This specific instance is being closed in favor of tracking the concern over on the referenced thread. Thanks for your report!

@microsoft-github-policy-service microsoft-github-policy-service bot added Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing. and removed 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 Apr 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. Resolution-Duplicate There's another issue on the tracker that's pretty much the same thing.
Projects
None yet
Development

No branches or pull requests

2 participants