Fix skipping over existing spaces when exporting to EBU STL

ac5f40a543 made it so that the N in \N was
skipped, but broke the space case, resulting in two spaces between each
word.

Closes #1887.
This commit is contained in:
Thomas Goyne 2016-03-05 16:31:28 -08:00
parent b2687e893b
commit 26fea0e123

View file

@ -284,17 +284,17 @@ namespace
text_rows.emplace_back(); text_rows.emplace_back();
cur_row = &text_rows.back(); cur_row = &text_rows.back();
cur_row->emplace_back("", underline, italic, true); cur_row->emplace_back("", underline, italic, true);
start = i + 2;
} }
else // if (substr == " " || substr == "\\n") else // if (substr == " " || substr == "\\n")
{ {
cur_row->back().text.append(" "); cur_row->back().text.append(" ");
cur_row->emplace_back("", underline, italic, true); cur_row->emplace_back("", underline, italic, true);
}
if (text[i] == '\\') start = i + 1 + (text[i] == '\\');
start = ++i + 1; }
else ++i;
start = i;
} }
// add the remaining text // add the remaining text