mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2025-02-16 20:15:38 +00:00
Fixed an issue where line breaks were included in single-line text entries.
This commit is contained in:
parent
508ea87963
commit
d927135034
|
@ -313,6 +313,10 @@ std::string Font::wrapText(const std::string& text,
|
||||||
|
|
||||||
for (size_t i = 0; i < text.length(); ++i) {
|
for (size_t i = 0; i < text.length(); ++i) {
|
||||||
if (text[i] == '\n') {
|
if (text[i] == '\n') {
|
||||||
|
if (!multiLine) {
|
||||||
|
addDots = true;
|
||||||
|
break;
|
||||||
|
}
|
||||||
wrappedText.append("\n");
|
wrappedText.append("\n");
|
||||||
accumHeight += lineHeight;
|
accumHeight += lineHeight;
|
||||||
lineWidth = 0.0f;
|
lineWidth = 0.0f;
|
||||||
|
|
Loading…
Reference in a new issue