diff --git a/sw/source/core/text/itrform2.cxx b/sw/source/core/text/itrform2.cxx index fcd49c15ba03..4c7f95867e13 100644 --- a/sw/source/core/text/itrform2.cxx +++ b/sw/source/core/text/itrform2.cxx @@ -1553,7 +1553,11 @@ xub_StrLen SwTxtFormatter::FormatLine( const xub_StrLen nStartPos ) pCurr->CalcLine( *this, GetInfo() ); CalcRealHeight( GetInfo().IsNewLine() ); - if ( IsFlyInCntBase() && !IsQuick() ) + //#i120864# For Special case that at the first calculation couldn't get + //correct height. And need to recalculate for the right height. + SwLinePortion* pPorTmp = pCurr->GetPortion(); + if ( IsFlyInCntBase() && (!IsQuick() || (pPorTmp && pPorTmp->IsFlyCntPortion() && !pPorTmp->GetPortion() && + pCurr->Height() > pPorTmp->Height()))) { KSHORT nTmpAscent, nTmpHeight; CalcAscentAndHeight( nTmpAscent, nTmpHeight );