From 8e45592c5703451563eaf4edcd7033f80ce23b53 Mon Sep 17 00:00:00 2001 From: Phil Jones Date: Fri, 12 Aug 2022 23:14:32 +0100 Subject: Add --fuzzy_match option. This enables some simple fuzzy matching logic for searches. --- src/desktop_vec.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/desktop_vec.h') diff --git a/src/desktop_vec.h b/src/desktop_vec.h index 85c885e..a731566 100644 --- a/src/desktop_vec.h +++ b/src/desktop_vec.h @@ -1,6 +1,7 @@ #ifndef DESKTOP_VEC_H #define DESKTOP_VEC_H +#include #include #include #include @@ -35,7 +36,8 @@ void desktop_vec_sort(struct desktop_vec *restrict vec); struct desktop_entry *desktop_vec_find(struct desktop_vec *restrict vec, const char *name); struct string_vec desktop_vec_filter( const struct desktop_vec *restrict vec, - const char *restrict substr); + const char *restrict substr, + bool fuzzy); struct desktop_vec desktop_vec_load(FILE *file); void desktop_vec_save(struct desktop_vec *restrict vec, FILE *restrict file); -- cgit v1.2.3