Method
GLibRegexreplace_literal
since: 2.14
Declaration [src]
gchar*
g_regex_replace_literal (
  const GRegex* regex,
  const gchar* string,
  gssize string_len,
  gint start_position,
  const gchar* replacement,
  GRegexMatchFlags match_options,
  GError** error
)
Description [src]
Replaces all occurrences of the pattern in regex with the
replacement text. replacement is replaced literally, to
include backreferences use g_regex_replace().
Setting start_position differs from just passing over a
shortened string and setting G_REGEX_MATCH_NOTBOL in the
case of a pattern that begins with any kind of lookbehind
assertion, such as “\b”.
Available since: 2.14
Parameters
- string
- 
            Type: An array of gcharThe string to perform matches against. The length of the array is specified in the string_lenargument.The data is owned by the caller of the method. Each element is a NUL terminated UTF-8 string. 
- string_len
- 
            Type: gssizeThe length of string, in bytes, or -1 ifstringis nul-terminated.
- start_position
- 
            Type: gintStarting index of the string to match, in bytes. 
- replacement
- 
            Type: const gchar*Text to replace each match with. The data is owned by the caller of the method. The value is a NUL terminated UTF-8 string. 
- match_options
- 
            Type: GRegexMatchFlagsOptions for the match. 
- error
- 
            Type: GError **The return location for a recoverable error. The argument can be NULL.If the return location is not NULL, then you must initialize it to aNULLGError*.The argument will be left initialized to NULLby the method if there are no errors.In case of error, the argument will be set to a newly allocated GError; the caller will take ownership of the data, and be responsible for freeing it.