incubator-ooo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chen...@apache.org
Subject svn commit: r1383798 - /incubator/ooo/trunk/main/sw/source/core/text/itrform2.cxx
Date Wed, 12 Sep 2012 06:25:25 GMT
Author: chengjh
Date: Wed Sep 12 06:25:24 2012
New Revision: 1383798

URL: http://svn.apache.org/viewvc?rev=1383798&view=rev
Log:
Fix issue #i120864: Text is overlapped by the drawing object when open the .doc file

* sw/source/core/text/itrform2.cxx
   Core function

Patch by: Jane Kang,<kangjane2012@gmail.com>
Found by: Yan Ji,<yanji.yj@gmail.com>
Review by: Jian Hong Cheng,<chengjh@apache.org>

Modified:
    incubator/ooo/trunk/main/sw/source/core/text/itrform2.cxx

Modified: incubator/ooo/trunk/main/sw/source/core/text/itrform2.cxx
URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/main/sw/source/core/text/itrform2.cxx?rev=1383798&r1=1383797&r2=1383798&view=diff
==============================================================================
--- incubator/ooo/trunk/main/sw/source/core/text/itrform2.cxx (original)
+++ incubator/ooo/trunk/main/sw/source/core/text/itrform2.cxx Wed Sep 12 06:25:24 2012
@@ -1572,7 +1572,11 @@ xub_StrLen SwTxtFormatter::FormatLine( c
         pCurr->CalcLine( *this, GetInfo() );
 		CalcRealHeight( GetInfo().IsNewLine() );
 
-		if ( IsFlyInCntBase() && !IsQuick() )
+		//Bug 120864:For Special case that at the first caculation couldn't get correct height.
And need to recaculate for the right height.
+		SwLinePortion* pPorTmp = pCurr->GetPortion();
+		if ( IsFlyInCntBase() && (!IsQuick() || (pPorTmp && pPorTmp->IsFlyCntPortion()
&& !pPorTmp->GetPortion() &&
+			pCurr->Height() > pPorTmp->Height())))
+		//Bug 120864(End)
 		{
 			KSHORT nTmpAscent, nTmpHeight;
 			CalcAscentAndHeight( nTmpAscent, nTmpHeight );



Mime
View raw message