Fix text-justify (fixes #444)

This commit is contained in:
John Firebaugh
2014-08-29 12:25:17 -07:00
parent 2e8fb5f667
commit eb1fbc542b

View File

@@ -131,7 +131,7 @@ void FontStack::lineWrap(Shaping &shaping, const float lineHeight, const float m
}
}
maxLineLength = maxLineLength || shaping.back().x;
if (!maxLineLength) maxLineLength = shaping.back().x;
justifyLine(shaping, metrics, lineStartIndex, uint32_t(shaping.size()) - 1, justify);
align(shaping, justify, horizontalAlign, verticalAlign, maxLineLength, lineHeight, line);