Skip to content

Commit ade7966

Browse files
author
Monte Goulding
committed
[[ Bug 17802 ]] Document how to escape special chars in filter patterns
1 parent 975bcda commit ade7966

2 files changed

Lines changed: 12 additions & 0 deletions

File tree

docs/dictionary/command/filter.lcdoc

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,17 @@ characters to match, which may be combined with any number of the following spec
6363
- [char-char] : Matches any character whose unicode codepoint is between the first character and the second character.
6464
- [!chars] : Matches any character which is not one of the characters inside the brackets.
6565

66+
You can match instances of special chars as follows:
67+
68+
- `?` with `[?]`
69+
- `*` with `[*]`
70+
- `[` with `[[]`
71+
- `-` with `-`
72+
- `!` with `!`
73+
74+
For example, the wildcard <filterPattern> `[[]A]*` will match any string
75+
beginning with `[A]`.
76+
6677
The three bracketed forms can be combined to create more complex character classes, for
6778
example the pattern [!abcA-C] matches any character which is not a, b or c (upper or lower case)
6879

docs/notes/bugfix-17802.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# Document how to escape special characters in wildcard filter patterns

0 commit comments

Comments
 (0)