ofxTextSuite
ofxTextSuite copied to clipboard
Justify not working properly for the last line of a paragraph
When there is a text block, the justify formatting tries to apply the rule to the last line of a paragraph. However, when there are a few words, they are placed so separated from the each other. I added these lines to the code (oftextBlock.cpp) in order to avoid this issue.
Lines : 175 if (l == lines.size() - 1) { //if it is the last line, avoid to justify pixelsPerSpace = blankSpaceWord.width; }else { pixelsPerSpace = ((boxWidth / scale) - (x / scale) - nonSpaceWordWidth) / spacesN; }