summaryrefslogtreecommitdiff
path: root/src/completion.hh
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2011-09-14 15:41:56 +0000
committerMaxime Coste <frrrwww@gmail.com>2011-09-14 15:41:56 +0000
commitb59ad6a174b49a049fd6789cbeb54dc40fd85fa1 (patch)
tree71c8a6c43696e080cc3bcfbe68c89e2516b24c69 /src/completion.hh
parent4b38cd3cd0131b2ab276310cc234ab666bd99363 (diff)
Completion: dedicated completion header and basic filename completion
Diffstat (limited to 'src/completion.hh')
-rw-r--r--src/completion.hh25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/completion.hh b/src/completion.hh
new file mode 100644
index 00000000..497fa54f
--- /dev/null
+++ b/src/completion.hh
@@ -0,0 +1,25 @@
+#ifndef completion_hh_INCLUDED
+#define completion_hh_INCLUDED
+
+#include <string>
+#include <vector>
+
+namespace Kakoune
+{
+
+typedef std::vector<std::string> CandidateList;
+
+struct Completions
+{
+ CandidateList candidates;
+ size_t start;
+ size_t end;
+
+ Completions(size_t start, size_t end)
+ : start(start), end(end) {}
+};
+
+CandidateList complete_filename(const std::string& prefix);
+
+}
+#endif // completion_hh_INCLUDED