From ff84c8e394391e0f0f05dc8f5281cba17405e5b8 Mon Sep 17 00:00:00 2001 From: Blaž Hrastnik Date: Fri, 7 May 2021 17:19:45 +0900 Subject: Command mode: Per command completers. --- helix-term/src/ui/mod.rs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'helix-term/src/ui/mod.rs') diff --git a/helix-term/src/ui/mod.rs b/helix-term/src/ui/mod.rs index 105ba7ad..a16b7ef0 100644 --- a/helix-term/src/ui/mod.rs +++ b/helix-term/src/ui/mod.rs @@ -114,6 +114,9 @@ pub fn file_picker(root: PathBuf) -> Picker { pub mod completers { use crate::ui::prompt::Completion; use std::borrow::Cow; + + pub type Completer = fn(&str) -> Vec; + // TODO: we could return an iter/lazy thing so it can fetch as many as it needs. pub fn filename(input: &str) -> Vec { // Rust's filename handling is really annoying. -- cgit v1.2.3-70-g09d2