X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fsupport%2Flstrings.h;h=576a5b921df363639c09e6cbc13d21b4123a1445;hb=ee9ff6cb0cd7d8b0ef3c18e5bd166e12580a3bf4;hp=66ea9df7057821894b6b816839503353f037b9b0;hpb=aafd52f44167d5510be1ddcb974daa9dae486933;p=lyx.git diff --git a/src/support/lstrings.h b/src/support/lstrings.h index 66ea9df705..576a5b921d 100644 --- a/src/support/lstrings.h +++ b/src/support/lstrings.h @@ -97,6 +97,8 @@ docstring const ascii_lowercase(docstring const &); /// Changes the case of \p s to lowercase. /// Does not depend on the locale. docstring const lowercase(docstring const & s); +// Currently unused, but the code is there if needed. +// std::string const lowercase(std::string const & s); /// Changes the case of \p s to uppercase. /// Does not depend on the locale. @@ -188,6 +190,9 @@ std::string const subst(std::string const & a, docstring const subst(docstring const & a, docstring const & oldstr, docstring const & newstr); +/// Count all occurences of char \a chr inside \a str +int count_char(std::string const & str, char chr); + /// Count all occurences of char \a chr inside \a str int count_char(docstring const & str, docstring::value_type chr); @@ -243,6 +248,7 @@ std::string const split(std::string const & a, char delim); /// Same as split but uses the last delim. std::string const rsplit(std::string const & a, std::string & piece, char delim); +docstring const rsplit(docstring const & a, docstring & piece, char_type delim); docstring const rsplit(docstring const & a, char_type delim); /// Escapes non ASCII chars and other problematic characters that cause