Files
LLeMbas-TTY/docs/config/lua/keyassignment/ActivateCommandPalette.md
T
mgpinf 9606fa2569 Add font configuration option for ActivateCommandPalette, CharSelect, PaneSelect (#6696)
* feat: option to configure font for ActivateCommandPalette, CharSelect, PaneSelect

Add configuration option for font for the below entities:
- ActivateCommandPalette
- CharSelect
- PaneSelect

For the above entities, if the font is not set in configuration, it
defaults to the font resolved in config.window_frame.font. This is in
order to maintain existing behavior of using the font resolved in
config.window_frame.font

* docs: documentation for added configuration options

Add documentation for below configuration options:
- command_palette_font
- char_select_font
- pane_select_font

* refactor: rename EntityFont to Entity

* docs: add example configuration in char_select_font

Apply changes mentioned in suggestion:
https://github.com/wezterm/wezterm/pull/6696#discussion_r1986085165

* docs: add example configuration in pane_select_font

Apply changes mentioned in suggestion:
https://github.com/wezterm/wezterm/pull/6696#discussion_r1986085165

* docs: add example configuration in command_palette_font

Apply changes mentioned in suggestion:
https://github.com/wezterm/wezterm/pull/6696#discussion_r1986085165

* refactor: calculate make_bold in make_entity_font_impl method

* refactor: resolve font_size based on Entity

Since we can fetch font_size based on entity, we resolve it in
'make_entity_font_impl'. This removes the need to pass the pref_size
parameter

Apply changes mentioned in suggestions:
https://github.com/wezterm/wezterm/pull/6696#discussion_r1986085350
https://github.com/wezterm/wezterm/pull/6696#discussion_r1986085949
2025-03-09 15:34:32 -07:00

1.5 KiB

ActivateCommandPalette

{{since('20230320-124340-559cb7b0')}}

Activates the Command Palette, a modal overlay that enables discovery and activation of various commands.

config.keys = {
  {
    key = 'P',
    mods = 'CTRL',
    action = wezterm.action.ActivateCommandPalette,
  },
}

CTRL + SHIFT + P is the default key assignment for ActivateCommandPalette.

The command palette shows a list of possible actions ranked by frecency of use from the command palette.

Command Palette

Key Assignments

Action Key Assignment
Exit command palette Esc
Highlight previous item UpArrow
Highlight next item DownArrow
Clear the selection CTRL + u
Activate the selection Enter

Typing text (and using Backspace) allows you to fuzzy match possible actions. Each keystroke will reduce the list of candidate actions to those that fuzzy match, ranked in decreasing order of the match score.

Activating the selected item will close the command palette and then invoke the action.

See also: