replace
Description:
[ Version ( deprecated = true , deprecated_since = "3.22" , since = "3.10" ) ]
public bool replace (TextIter match_start, TextIter match_end, string replace, int replace_length) throws Error
public bool replace (TextIter match_start, TextIter match_end, string replace, int replace_length) throws Error
Warning: replace is deprecated since 3.22.
Replaces a search match by another text.
Note:
Use replace2 instead.
If match_start
and match_end
doesn't correspond to a search match, false
is returned.
For a regular expression replacement, you can check if replace
is valid by calling
check_replacement. The replace
text can contain
backreferences; read the replace documentation for more details.
Parameters:
this | |
match_start |
the start of the match to replace. |
match_end |
the end of the match to replace. |
replace |
the replacement text. |
replace_length |
the length of |
Returns:
whether the match has been replaced. |