Regex.newForSearch

vte.regex.Regex newForSearch(string pattern, uint flags)

Compiles pattern into a regex for use as a search regex with [vte.terminal.Terminal.searchSetRegex].

See man:pcre2pattern(3) for information about the supported regex language, and man:pcre2api(3) for information about the supported flags.

The regex will be compiled using <literal>PCRE2_UTF</literal> and possibly other flags, in addition to the flags supplied in flags.

Parameters

patterna regex pattern string
flagsPCRE2 compile flags

Returns

a newly created #VteRegex, or null with error filled in

Throws

[ErrorWrap]