-
Notifications
You must be signed in to change notification settings - Fork 8.3k
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
Command Palette: Action and command line mode in relation to char > #7736
Comments
Oh my gosh you're right, we did end up doing this backwards from VsCode. I even had it called out in the spec to do it the other way: Cmd Palette Spec. That whole section is labeled with a bunch of "for discussion" tags, but I guess I never updated the spec to reflect the final decision-making point: #5674 (comment)
We're definitely in a weird place here - we already shipped the CmdPal with |
Glad I at least posted this then, and that it was an oversight. To make progress in the world of all that is coding, I do think a change is warranted and I am not sure many users would be angry if a change was made. The reason being that the default of pressing tldr; I think most users would find this an improvement (even if we do not take VS Code into account). |
Summoning @DHowett, @cinnamon-msft. What do y'all think - do we follow PowerToys run, or VsCode? |
If we start with |
It would list the available commad options. Exactly like in VS Code. (if the question was aimed at me) |
Then I think we should follow VS Code for this. We've followed them for the key binding, might as well keep it going. :) |
Meh, let's just flip it. It starts with FWIW: VS Code doesn't have a commandline invocation mode, so there's no real parallel here. How do other popular editors handle this? How about terminal emulators? |
That is true, but for what it is worth it has another mode (file mode) when the |
Thanks for the feedback y'all. I'll throw this on my 1.5 plate, so we don't ship the CmdPal with the original behavior for too long. I'm not sure there's any other precedent for a command palette in other terminal emulators, so that's not really a factor here. Sublime Text's "action mode" has no prefix, but also so does the "navigate to file" mode. They're just on separate keybinds. "Go to reference" (e.g. function name) is on the prefix |
Oof, this is a little trickier than just "flip the logic around" - we're going to have to fake out the placeholder text for action mode now, because it will have a literal Annoying, but fixable. |
VsCode uses `>` as its "prefix" for the equivalent of their "action mode". This PR aligns the Terminal with their logic here. We have to be tricky - if we use the `>` in the actual input as the indicator for action mode, we can't display any placeholder text in the input to tell users to type a command. This wasn't an issue for the commandline mode previously, because we'd stick the "prompt" in the "no matches text" space. However, we can't do that for action mode. Instead, we'll stick a floating text block over the input box, and when the user's in action mode, we'll manually place a `>` into that space. When the user backspaces the `>`, we'll remove it from that block, and switch into commandline mode. ## Validation Steps Performed Played with the cmdpal in lots of different modes, this finally feels good Closes #7736
🎉This issue was addressed in #7935, which has now been successfully released as Handy links: |
Description of the new feature/enhancement
In VS Code, pressing
ctrl+shift+p
opens the command palette with>
.In Windows terminal, pressing
ctrl+shift+p
opens the command palette without>
.But both mean the same thing i.e. if I enter some text I find commands to execute.
As I expect many users will use VS Code + Windows Terminal when developing on Windows, would it not be better to correlate these? The benefits are:
>
means the same thing for both apps, which decreases cognitive load.>
than it is to add the>
.I.e. I think the
>
should instead mean "action mode" whilst no>
will mean command line mode, according to https://devblogs.microsoft.com/commandline/windows-terminal-preview-1-3-release/ (see under "Command palette").I realize this might have been discussed when implementing this, but in that case and if this issue is closed, it might serve as a reference to other users being confused by this unfortunate discrepancy.
The text was updated successfully, but these errors were encountered: