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

Have a way of actually knowing the geometry of the terminal #18025

Closed
steviator opened this issue Oct 10, 2024 · 3 comments
Closed

Have a way of actually knowing the geometry of the terminal #18025

steviator opened this issue Oct 10, 2024 · 3 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

@steviator
Copy link

Description of the new feature/enhancement

A method by which the size of the terminal in rows and columns could be determined after resizing the window or changing font size

Proposed technical implementation details (optional)

In every other terminal emulator that I have ever used going back to Windows 3.1 there has been some method of determining the Window size of the terminal in use, either by reading something like the title-bar, status bar or a pop-up that appears while resizing the window or by directly forcing the window to a desired geometry using escape codes like Unix, or a command like ms-dos MODE.

None of these methods work in Windows Terminal and to make matters worse, the window size remains the same if you change the font size, causing the window geometry to change to unknowable values.

For Microsoft to implement one or more of the many established ways of determining the size of a terminal, this isn't rocket surgery.

Examples:

  • A pop-up that states the window size in rows and columns while resizing
  • Optionally displaying the window size in the title
  • Supporting escape codes to set the window size in rows and columns
  • Supporting the same commands to set the window size as conhost.exe
  • Something new and great dreamed up by the Windows Terminal developers
@steviator steviator added the Issue-Feature Complex enough to require an in depth planning process and actual budgeted, scheduled work. label Oct 10, 2024
@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 Oct 10, 2024
@j4james
Copy link
Collaborator

j4james commented Oct 10, 2024

A method by which the size of the terminal in rows and columns could be determined after resizing the window or changing font size

If you mean programmatically, you can query the size with a CSI 18 t escape sequence.

A pop-up that states the window size in rows and columns while resizing

This feature request is tracked in issue #2833.

Supporting escape codes to set the window size in rows and columns

Support for resizing with a CSI 8 t escape sequence was recently added in PR #17721. That functionality should be working in the nightly build. But note that it's only applicable when you have a single tab with a single pane. Other scenarios are tracked in issue #5094.

Supporting the same commands to set the window size as conhost.exe

That's also tracked in issue #5094.

@carlos-zamora
Copy link
Member

Thanks for filing! We'll mark this as a /dup of #2833. Thanks for looking into this @j4james 😊

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 Oct 16, 2024
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

3 participants