-
Notifications
You must be signed in to change notification settings - Fork 8.4k
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
Quake mode: Add support for reserved tabs #10279
Comments
LGTM. The first option with guid names seems more flexible but I would replace the
Sadly, that'd made this a duplicate of #9992, and this should be closed 'cause #9992 seems to be a more uniform and flexible approach. |
Disagreed: #9992 doesn’t come close to the core request for this, which is the ability to summon the windows *and* switch to a tab with a fixed name. That “and” is critical, as is having a stable identifier for a tab: Doing it by position as initially spawned via a startup action doesn’t work – positions (and titles, as noted in a separate issue) can change, whereas identifiers are constants.
This feature request is orthogonal to your suggestion of having startup actions.
|
Ok, now I see what you mean. Maybe there should be an additional It'd require some kind of "discrimination keybinding" and/or "tab switcher" applied N times over the exact same profile. Some kind of circular keybinding like the tab switcher's |
Uniqueness of identifiers is a general presumption about identifiers 😊
This is why I wouldn’t key it off of things like “title”, which is absolutely intended to change. Similarly, I wouldn’t base it on which profile was attached to the particular tab, since there are easy example of needing, say, multiple PS windows. Though you could simply resolve the ambiguity by spinning up a new profile with a slightly different launch command.
Defining things window-wise feels easier to think about, but defining things profile-wise is simpler to implement (don’t need to add new entities to the settings model, just a pair of new properties).
If defined profile-wise, the presence of these two properties would be sufficient to block traditional instantiation, so we wouldn’t have the issue of two instances of the same tab: WT would explicitly take over and manage the lifecycle of such tabs as I suggest earlier.
|
I apologize. I've committed a mistake. I meant two tabs, each one with an instance of the same profile, and both inside the same window. I'm not really sure I got it right. Do you mean something like the |
Uniqueness of identifiers means those tabs would be distinguishable. It would be a syntactic error in the profile to permit collisions.
|
Strictly speaking, that's not true.
You'll clearly see that each one is strictly deterministic, even the Pseudo-Random one, therefore the uniqueness holds if, and only if the seed, or set of seeds, is unique itself; the UUID uniqueness is directly inherited from its seeds uniqueness.
How'd you prevent collisions while, at the same time, enable a way to know a tab's GUID prior the actual tab's creation?
I'm pretty sure we all agree that a profile is just a pattern of initialization for any tab's pane, therefore it cannot be linked to a single tab or pane. While a pane must always reference one, and only one profile, a profile can be referenced from N panes without restriction; it just make no sense talking about tab collisions within a profile context, 'cause profiles apply to panes, not tabs. |
You're not presenting any particular argument against this. This is not a difficult or even novel concept in programming and, honestly, it comes off at grasping for straw men.
—
Keith J. Farmer
|
If anything, d, you're demonstrating that you didn't read the suggestion: it is (again) to provide the very names to tabs that would be used in summoning. This is entirely configured by the user, and UUID creation algorithms are irrelevant.
—
Keith J. Farmer
|
I read your suggestion and I fully understood it, but I'm not sure I've explained myself right. What you call tab, is actually a collection of panes, and the name of a pane is, in fact, the name of the profile loaded inside it, as well as many other inherited properties like background, tab color, GUID, etc. Due to its focus inheritance nature, conceptually, I guess there's no such thing like a tab ID, despite its position, 'cause it's just a simple group of panes created for the sole purpose of easing the navigation, and the properties of each of these pseudo-groups called tabs relays entirely on its currently focused pane. I see that you'd like to have some kind of unique ID for each tab. You called it name and I called it GUID; let's call it UID (Unique ID). If you reformulate this suggestion, it mainly asks for adding the next properties inside the window entity that #9992 proposes:
As you see, I added a few more interesting properties and enabled managing multiple panes too, but it does not make this a new issue. I'd still consider it as a comment for enhancement to #9992. In fact, that's exactly what I'm going to do right now. |
it has nothing to do with 9992, and I'd appreciate it if you'd stop hijacking other people's suggestions.
|
I'm so sorry but you clearly misunderstood my intentions 'cause I've never meant to hijack anything from anyone. In addition, I always give the credit to whom it belongs, as you can see in the first line of the last comment I've written in 9992. I really look for this feature to become available so everyone can benefit from it! 😊 👍 |
Okay so this issue sounds to me like two separate requests:
Focusing on just the first half of the request (as discussion on the second is probably best saved for #5969) - I'm not sure there's a simple way to express that. Given the possible scenarios that a user might want for that, IMO, the mentally easiest model is to just press two keybindings. win+`, ctrl+alt+2 is a little bit of keyboard gymnistics, but you could always rebind actions so that it's easier. If you want to get weird, you could bind: { "keys": "win+alt+1", "command": { "action": "globalSummon" } },
{ "keys": "win+alt+2", "command": { "action": "globalSummon" } },
{ "keys": "win+alt+3", "command": { "action": "globalSummon" } },
{ "keys": "win+alt+4", "command": { "action": "globalSummon" } },
//... (to bind all of win+alt+N to "summon the window"), Then, do something like win+alt+2, ctrl+alt+2 to not have to move that many fingers. |
This issue has been automatically marked as stale because it has been marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. |
That looks like a reasonable compromise. |
Awesome, thanks for following up! |
.. wait. the compromise I had in mind still begs having tab switching as part of summon. otherwise it's status quo, and nothing is solved.
—
Keith J. Farmer
…________________________________
From: Mike Griese ***@***.***>
Sent: Monday, July 12, 2021 8:03:50 AM
To: microsoft/terminal ***@***.***>
Cc: Keith J. Farmer ***@***.***>; Author ***@***.***>
Subject: Re: [microsoft/terminal] Quake mode: Add support for reserved tabs (#10279)
Closed #10279<#10279>.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub<#10279 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ACLMBSBKDPSNYEN4UMKITZDTXL75NANCNFSM45YZWV7Q>.
|
Sorry, this got lost in my mailbox and I'm just thinking of it again. I'm resurrecting this, because it tracks well with another thread I'm about to file. Proposal:
|
Description of the new feature/enhancement
The current quake mode implementation entails a window with a well-known name. This window gets specially handled with regard to summoning: it gets docked and focus mode is turned on. It is otherwise a normal window capable of hosting multiple tabs.
There are existing requests filed for supporting multiple quake mode windows, each with a different profile running. That seems unnecessary given the ability for an existing terminal window to host multiple profiles already. What is lacking is the ability to specify which tab to bring active on summon.
Proposed technical implementation details (optional)
Allow the ability to define reserved tabs by name:
or, alternatively, add "window" and "tab" names to the existing profile schema, binding them exclusively:
Then add an argument to wt.exe that allows specification of the specific tab name to activate (or, if the alternative approach is taken, a profile which has a window and tab name defined). If it is not already live, it will be activated. In this way, hot keys can be defined to summon specific tabs.
On exit or close of any of the named tabs, the tab will remain open, waiting to restart the command in question (immediately, if currently active).
Additional tabs created in the window will follow after the named tabs.
The text was updated successfully, but these errors were encountered: