From 5e692b213adaa0728c3ec5ccb000b88241e86cac Mon Sep 17 00:00:00 2001 From: zanqdo Date: Tue, 11 Apr 2023 18:13:46 -0600 Subject: [PATCH 1/2] Add the slash char to the fuzzy search separators --- source/blender/blenlib/intern/string_search.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/blender/blenlib/intern/string_search.cc b/source/blender/blenlib/intern/string_search.cc index f87304863c9..e63b88ec74f 100644 --- a/source/blender/blenlib/intern/string_search.cc +++ b/source/blender/blenlib/intern/string_search.cc @@ -346,13 +346,14 @@ void extract_normalized_words(StringRef str, Vector &r_words) { const uint32_t unicode_space = uint32_t(' '); + const uint32_t unicode_slash = uint32_t('/'); const uint32_t unicode_right_triangle = UI_MENU_ARROW_SEP_UNICODE; BLI_assert(unicode_space == BLI_str_utf8_as_unicode(" ")); BLI_assert(unicode_right_triangle == BLI_str_utf8_as_unicode(UI_MENU_ARROW_SEP)); auto is_separator = [&](uint32_t unicode) { - return ELEM(unicode, unicode_space, unicode_right_triangle); + return ELEM(unicode, unicode_space, unicode_slash, unicode_right_triangle); }; /* Make a copy of the string so that we can edit it. */ -- 2.30.2 From e5fcb97813d2d03e2958d3c1ea1bcfdc3c44cd91 Mon Sep 17 00:00:00 2001 From: zanqdo Date: Tue, 11 Apr 2023 18:19:30 -0600 Subject: [PATCH 2/2] Missing BLI_assert --- source/blender/blenlib/intern/string_search.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/source/blender/blenlib/intern/string_search.cc b/source/blender/blenlib/intern/string_search.cc index e63b88ec74f..50bbc253346 100644 --- a/source/blender/blenlib/intern/string_search.cc +++ b/source/blender/blenlib/intern/string_search.cc @@ -350,6 +350,7 @@ void extract_normalized_words(StringRef str, const uint32_t unicode_right_triangle = UI_MENU_ARROW_SEP_UNICODE; BLI_assert(unicode_space == BLI_str_utf8_as_unicode(" ")); + BLI_assert(unicode_slash == BLI_str_utf8_as_unicode("/")); BLI_assert(unicode_right_triangle == BLI_str_utf8_as_unicode(UI_MENU_ARROW_SEP)); auto is_separator = [&](uint32_t unicode) { -- 2.30.2