diff options
author | László Németh <nemeth@numbertext.org> | 2014-07-01 00:18:13 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2014-07-01 15:34:34 +0000 |
commit | 891652082c4d09cc069f1902ba19e4bd96e8c384 (patch) | |
tree | a9d047f22984960bb3743abd1527659e9e51a973 | |
parent | 5955e7d66d9b0e87f93fd9746a85bff132da9794 (diff) |
fdo#79372, fdo#56392 fix hyphenation
Change-Id: Iacf84d023d3b4795892bc444299a29bfc663345e
Reviewed-on: https://gerrit.libreoffice.org/10001
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r-- | i18npool/source/breakiterator/breakiterator_unicode.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/i18npool/source/breakiterator/breakiterator_unicode.cxx b/i18npool/source/breakiterator/breakiterator_unicode.cxx index 126ac7a8d354..5270b1db5bad 100644 --- a/i18npool/source/breakiterator/breakiterator_unicode.cxx +++ b/i18npool/source/breakiterator/breakiterator_unicode.cxx @@ -398,7 +398,7 @@ LineBreakResults SAL_CALL BreakIterator_Unicode::getLineBreak( uno::Reference< linguistic2::XHyphenatedWord > aHyphenatedWord; aHyphenatedWord = hOptions.rHyphenator->hyphenate(Text.copy(wBoundary.startPos, wBoundary.endPos - wBoundary.startPos), rLocale, - (sal_Int16) (hOptions.hyphenIndex - wBoundary.startPos - nStartPosWordEnd), hOptions.aHyphenationOptions); + (sal_Int16) (hOptions.hyphenIndex - wBoundary.startPos - ((hOptions.hyphenIndex == wBoundary.endPos)? nStartPosWordEnd : 0)), hOptions.aHyphenationOptions); if (aHyphenatedWord.is()) { lbr.rHyphenatedWord = aHyphenatedWord; if(wBoundary.startPos + aHyphenatedWord->getHyphenationPos() + 1 < nMinBreakPos ) |