on master help sign in
Add command names to command palette (#4071)
576c34fnuid32
helix-term/src/commands.rs+2−2
@@ -2427,11 +2427,11 @@ impl ui::menu::Item for MappableCommand {
2427
2427
2428 match self {
2428 match self {
2429 MappableCommand::Typable { doc, name, .. } => match keymap.get(name as &String) {
2429 MappableCommand::Typable { doc, name, .. } => match keymap.get(name as &String) {
2430− Some(bindings) => format!("{} ({})", doc, fmt_binding(bindings)).into(),
2430+ Some(bindings) => format!("{} ({}) [{}]", doc, fmt_binding(bindings), name).into(),
2431 None => doc.as_str().into(),
2431 None => doc.as_str().into(),
2432 },
2432 },
2433 MappableCommand::Static { doc, name, .. } => match keymap.get(*name) {
2433 MappableCommand::Static { doc, name, .. } => match keymap.get(*name) {
2434− Some(bindings) => format!("{} ({})", doc, fmt_binding(bindings)).into(),
2434+ Some(bindings) => format!("{} ({}) [{}]", doc, fmt_binding(bindings), name).into(),
2435 None => (*doc).into(),
2435 None => (*doc).into(),
2436 },
2436 },
2437 }
2437 }