X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2Fsupport%2Flstrings.cpp;h=9eb9e43d5fbe975367e8b527f313db11f4fdee7e;hb=bf56e2c8e1afa857cd5e313c19948040e41b8227;hp=2c3203b5c72f441baf5e5d96de303715708b2b1c;hpb=efbec203202e5ff1322aa44a7ecd1ec53d17c552;p=lyx.git diff --git a/src/support/lstrings.cpp b/src/support/lstrings.cpp index 2c3203b5c7..9eb9e43d5f 100644 --- a/src/support/lstrings.cpp +++ b/src/support/lstrings.cpp @@ -717,6 +717,12 @@ bool containsOnly(string const & s, string const & cset) } +bool containsOnly(docstring const & s, string const & cset) +{ + return s.find_first_not_of(from_ascii(cset)) == string::npos; +} + + // ale970405+lasgoutt-970425 // rewritten to use new string (Lgb) string const token(string const & a, char delim, int n)