13#include <rtl/ustrbuf.hxx>
21 OUStringBuffer buffer;
23 bool lastCharacterWasWhitespace =
false;
24 for (
size_t pos = 0;
pos < inputString.size(); ++
pos) {
27 if (cur ==
' ' || cur ==
'\n' || cur ==
'\t') {
29 if (!lastCharacterWasWhitespace) {
32 lastCharacterWasWhitespace =
true;
36 lastCharacterWasWhitespace =
false;
41 if (lastCharacterWasWhitespace) {
42 buffer.truncate(buffer.getLength() - 1);
55 SAL_WARN(
"sw.core",
"Requested position of TOX entry text which does not exist. "
56 "Maybe the formatting hint is corrupt?");
std::vector< sal_Int32 > mNewPositions
ToxWhitespaceStripper(std::u16string_view)
sal_Int32 GetPositionInStrippedString(sal_Int32 pos) const
#define SAL_WARN(area, stream)
constexpr std::enable_if_t< std::is_signed_v< T >, std::make_unsigned_t< T > > make_unsigned(T value)
Dialog to specify the properties of date form field.