Add config option for literal search queries #12

Closed
hubgit wants to merge 1 commit from literal-backslash into main
hubgit commented 2022-04-19 22:13:29 +02:00 (Migrated from github.com)

As it's quite common when writing LaTeX to have text which contains \t (e.g. \textbf), \n (e.g. \newpage) or \r (e.g. \rightarrow), it would be useful if a search query could have an option to disable the automatic conversion of these characters.

The config option added in this branch seems to have the desired effect, but the name of the config option is debatable (it could be exact, perhaps, or something else).

It's still possible to match newlines (for example) by entering \n, but only in regex mode.

As it's quite common when writing LaTeX to have text which contains `\t` (e.g. `\textbf`), `\n` (e.g. `\newpage`) or `\r` (e.g. `\rightarrow`), it would be useful if a search query could have an option to disable the automatic conversion of these characters. The config option added in this branch seems to have the desired effect, but the name of the config option is debatable (it could be `exact`, perhaps, or something else). It's still possible to match newlines (for example) by entering `\n`, but only in regex mode.
marijnh commented 2022-04-20 17:25:37 +02:00 (Migrated from github.com)

Merged as 5353fd9059, clarified doc comment in fe6f7d3d69

Merged as 5353fd905902da13d8aaff1ba427c79ea9c1ef92, clarified doc comment in fe6f7d3d69958f9

Pull request closed

Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
codemirror/search!12
No description provided.