The search and Replace window provides controls to quickly find specific or partial text in accordance with defined search options, then replace that text with specified new text.
The search and replace window can be opened by selecting the Search and Replace option from the segment grid column header menu, or via translate5 shortcuts:
The following table illustrates some commonly used metacharacters and constructs in a regular expression, that are allowed to use in translate5:
Metacharacter | Behavior |
---|---|
^ | matches the position at the beginning of the searched string |
$ | matches the position at the end of the searched string |
[…] | matches any character specified inside the square brackets |
[^…] | matches any character not specified inside the square brackets |
* | matches the preceding character zero or more times |
+ | matches preceding character one or more times |
{n} | matches n number of instances of the preceding character |
{m,n} | matches from m to n number of instances of the preceding character |
The following list contains the regular expressions and regular expressions, which are not supported by translate5, because they are black-listed:
Regex | Description |
---|---|
\n | Character escape |
\r | Character escape |
\t | Character escape |
\f | Character escape |
\v | Character escape |
\0 | NULL escape |
\1 or \2 etc. | Octal escape (Any character with a character code lower than 256 ex: \251 ) |
Some Characters | Some Characters | Using | for and "or" regex |
\^ or \] or \- or \\ | \ (backslash) followed by any of ^-]\ |
\b | javascript: [\b\t] matches a backspace or a tab character. |
\B | javascript: \B. matches b, c, e, and f in abc def |
\d | Shorthand Character Classes |
\D | Shorthand Character Classes |
\s | Shorthand Character Classes |
\S | Shorthand Character Classes |
\w | Shorthand Character Classes |
\W | Shorthand Character Classes |
\h | Shorthand Character Classes |
?? | e. g. a regular expression like abc?? is not supported. |
*? | |
+? | |
OTHERS | Other regular expressions, that are similar to the listed expressions are also not supported. The front-end of translate5 will tell you, if a regex is not supported. Please contact translate5 lead development at MittagQI, if you have more questions about this. |