From f052e1becbd0e62002c2a98ae258432546e4990e Mon Sep 17 00:00:00 2001 From: attila Date: Tue, 7 Dec 2021 11:29:42 +0100 Subject: [PATCH] Fix CharPointer_UTF8::isWhitespace() when encountering ideographic whitespace --- modules/juce_core/text/juce_CharPointer_UTF8.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/juce_core/text/juce_CharPointer_UTF8.h b/modules/juce_core/text/juce_CharPointer_UTF8.h index 475d84e4d5..6b65c245f8 100644 --- a/modules/juce_core/text/juce_CharPointer_UTF8.h +++ b/modules/juce_core/text/juce_CharPointer_UTF8.h @@ -449,7 +449,7 @@ public: } /** Returns true if the first character of this string is whitespace. */ - bool isWhitespace() const noexcept { const CharType c = *data; return c == ' ' || (c <= 13 && c >= 9); } + bool isWhitespace() const noexcept { return CharacterFunctions::isWhitespace ((juce_wchar) *(*this)); } /** Returns true if the first character of this string is a digit. */ bool isDigit() const noexcept { const CharType c = *data; return c >= '0' && c <= '9'; } /** Returns true if the first character of this string is a letter. */