mirror of
https://github.com/geode-sdk/geode.git
synced 2024-11-14 19:15:05 -05:00
Fixed a bug where only 1 word wrap variant can exist (#1058)
* Fixed a bug where only 1 word wrap variant can exist * Made the delimiters a string view
This commit is contained in:
parent
444a8c198b
commit
d0eb881ebc
1 changed files with 1 additions and 1 deletions
|
@ -209,7 +209,7 @@ void SimpleTextArea::updateLinesNoWrap() {
|
|||
|
||||
void SimpleTextArea::updateLinesWordWrap(bool spaceWrap) {
|
||||
this->charIteration([this, spaceWrap](CCLabelBMFont* line, const char c, const float top) {
|
||||
static const std::string delimiters(spaceWrap ? " " : " `~!@#$%^&*()-_=+[{}];:'\",<.>/?\\|");
|
||||
const std::string_view delimiters(spaceWrap ? " " : " `~!@#$%^&*()-_=+[{}];:'\",<.>/?\\|");
|
||||
|
||||
if (delimiters.find(c) == std::string_view::npos) {
|
||||
const std::string& text = line->getString();
|
||||
|
|
Loading…
Reference in a new issue