tdf#145496 Add dropped nLineWidth from refactoring
Regression from commit 4fc1b3fb659be916167518b49ffe8193e9033f30
("flatten ImplGetTextLines").
Change-Id: Ib9f086243b4e3ae245263492e714de6f81b89ea1
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/124557
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Reviewed-by: Jan-Marek Glogowski <glogow@fbihome.de>
Tested-by: Jenkins
diff --git a/vcl/source/outdev/text.cxx b/vcl/source/outdev/text.cxx
index 57a8a1e..8557ba2 100644
--- a/vcl/source/outdev/text.cxx
+++ b/vcl/source/outdev/text.cxx
@@ -523,7 +523,10 @@ tools::Long OutputDevice::ImplGetTextLines( const tools::Rectangle& rRect, const
xBI = vcl::unohelper::CreateBreakIterator();
if ( xBI.is() )
{
nBreakPos = ImplBreakLinesWithIterator(nWidth, rStr, _rLayout, xHyph, xBI, bHyphenate, nPos, nBreakPos);
nLineWidth = _rLayout.GetTextWidth(rStr, nPos, nBreakPos - nPos);
}
else
// fallback to something really simple
nBreakPos = ImplBreakLinesSimple(nWidth, rStr, _rLayout, nPos, nBreakPos, nLineWidth);