From 76f1f88ba62bfbb4f36a364acd2afe133d490304 Mon Sep 17 00:00:00 2001 From: Ziaft Date: Sun, 2 Oct 2022 20:36:38 +0000 Subject: [PATCH] Add command names to command palette --- helix-term/src/commands.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/helix-term/src/commands.rs b/helix-term/src/commands.rs index c87ad0ca229c..38a86041c4d5 100644 --- a/helix-term/src/commands.rs +++ b/helix-term/src/commands.rs @@ -2410,11 +2410,11 @@ impl ui::menu::Item for MappableCommand { match self { MappableCommand::Typable { doc, name, .. } => match keymap.get(name as &String) { - Some(bindings) => format!("{} ({})", doc, fmt_binding(bindings)).into(), + Some(bindings) => format!("{} ({}) [{}]", doc, fmt_binding(bindings), name).into(), None => doc.as_str().into(), }, MappableCommand::Static { doc, name, .. } => match keymap.get(*name) { - Some(bindings) => format!("{} ({})", doc, fmt_binding(bindings)).into(), + Some(bindings) => format!("{} ({}) [{}]", doc, fmt_binding(bindings), name).into(), None => (*doc).into(), }, }