diff options
Diffstat (limited to 'dw/textblock_linebreaking.cc')
-rw-r--r-- | dw/textblock_linebreaking.cc | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/dw/textblock_linebreaking.cc b/dw/textblock_linebreaking.cc index c98596c6..bac23cb9 100644 --- a/dw/textblock_linebreaking.cc +++ b/dw/textblock_linebreaking.cc @@ -487,7 +487,7 @@ void Textblock::wordWrap (int wordIndex, bool wrapAll) accumulateWordData (wordIndex); - int penaltyIndex = 0; + int penaltyIndex = calcPenaltyIndexForNewLine (); bool newLine; do { @@ -615,6 +615,7 @@ void Textblock::wordWrap (int wordIndex, bool wrapAll) tempNewLine ? "temporally" : "permanently", firstIndex, breakPos); lineAdded = true; + penaltyIndex = calcPenaltyIndexForNewLine (); } else { // TODO hyphenateWord() should return whether something has // changed at all. So that a second run, with |