mirror of
https://github.com/lbonn/rofi
synced 2024-11-26 22:00:20 +00:00
Fuzzy matcher, take simple escaping into account when creating regex.
This commit is contained in:
parent
4f3c7f122e
commit
84f7ec2f0e
1 changed files with 5 additions and 0 deletions
|
@ -181,6 +181,11 @@ static gchar *fuzzy_to_regex ( const char * input )
|
|||
else {
|
||||
g_string_append ( str, ".*(" );
|
||||
}
|
||||
if ( *iter == '\\' ){
|
||||
g_string_append_c ( str, '\\');
|
||||
iter = g_utf8_next_char ( iter );
|
||||
if ( iter == NULL ) break;
|
||||
}
|
||||
g_string_append_unichar ( str, g_utf8_get_char ( iter ) );
|
||||
g_string_append ( str, ")" );
|
||||
first = 0;
|
||||
|
|
Loading…
Reference in a new issue