Skip to content

Allow commands to be previewed in the command palette #6689

Closed

Description

Use cases:

  • Switching schemes - I want to be able to see what the scheme will look like, before I commit to it
  • Changing opacity - I'm thinking we have a nested "Change opacity..."/["opacity: 0%", "opacity: 5%", "opacity: 10%"...] commands, and as they key through them, it updates in real time
  • Probably useful with the tab switcher

These would need to be commands that could be undo-able. Commands where we could build a "reset" command given the current state of the Terminal, and hitting esc to dismiss the palette would revert to the original state.

I'd imagine that not all commands could be previewed. Can't preview "open a new tab".

If you went from one previewable command to another of the same action type, then we don't need to reset in between. But going from a "see theme to foo"->"set opacity to 5%" commands, we'd need to undo the first, then cache the state for the second command.

Could probably have some ActionArgs implement IPreviewable, with a ActionAndArgs GenerateUndoCommand(AppLogic); method. Anything that's "preview":true would need to implement that interface.

</showerthought>

Considered use cases:

  • Switching to another color scheme
  • changing the font size
  • changing the font face
  • changing the opacity of acrylic
  • Switching tabs (like in the ATS, Advanced Tab Switcher #6732)

Activity

  1. added
    Area-UserInterfaceIssues pertaining to the user interface of the Console or Terminal
    Area-SettingsIssues related to settings and customizability, for console or terminal
    Issue-TaskIt's a feature request, but it doesn't really need a major design.
    on Jun 26, 2020
  2. ghost added
    Needs-TriageIt's a new issue that the core contributor team needs to triage at the next triage meeting
    on Jun 26, 2020
  3. removed
    Needs-TriageIt's a new issue that the core contributor team needs to triage at the next triage meeting
    on Jul 10, 2020
  4. DHowett commented on Jul 10, 2020

    @DHowett
    Member

    I wonder if it's as "easy" as having the "active TerminalSettings context" and manipulating that, and then either reverting to the existing one or committing the new one as the active one.

  5. DHowett commented on Jul 10, 2020

    @DHowett
    Member

    So like, the command always manipulates (permanently!) the state. We just make a copy, and discard it to undo.

  6. zadjii-msft commented on Jul 10, 2020

    @zadjii-msft
    MemberAuthor

    That's so so so much easier

  7. ghost added a commit that references this issue on Oct 7, 2020
  8. ghost added
    In-PRThis issue has a related PR
    on Apr 13, 2021
  9. ghost closed this as completedin #9794on Apr 21, 2021
  10. ghost removed
    In-PRThis issue has a related PR
    on Apr 21, 2021
  11. ghost added
    Resolution-Fix-CommittedFix is checked in, but it might be 3-4 weeks until a release.
    on Apr 21, 2021
  12. ghost added a commit that references this issue on Apr 21, 2021
    546322b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Area-CmdPalCommand Palette issues and featuresArea-SettingsIssues related to settings and customizability, for console or terminalArea-UserInterfaceIssues pertaining to the user interface of the Console or TerminalIssue-TaskIt's a feature request, but it doesn't really need a major design.Product-TerminalThe new Windows Terminal.Resolution-Fix-CommittedFix is checked in, but it might be 3-4 weeks until a release.

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions