diff options
author | Jan Holesovsky <kendy@suse.cz> | 2011-03-18 15:59:29 +0100 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2011-03-18 15:59:29 +0100 |
commit | 75a78c3224b3aa4b626381b8f4993019a2ea4036 (patch) | |
tree | 9de4fc4a455e66d5d478dbfb97655e09fef3ec2c /sw/source/core/text/itrcrsr.cxx | |
parent | 1cb177f424942549b547c2113129d607dec3c1e5 (diff) | |
parent | ae9f68d1e73a973046deee6fd602a2a4c3eba2a3 (diff) |
Merge remote-tracking branch 'origin/integration/dev300_m101'
Conflicts:
starmath/source/symbol.cxx
sw/source/core/doc/docnew.cxx
sw/source/core/doc/docnum.cxx
sw/source/core/draw/dview.cxx
sw/source/core/fields/docufld.cxx
sw/source/core/layout/calcmove.cxx
sw/source/filter/html/swhtml.cxx
sw/source/filter/rtf/rtftbl.cxx
sw/source/ui/config/modcfg.cxx
sw/source/ui/dialog/docstdlg.cxx
sw/source/ui/dialog/docstdlg.src
sw/source/ui/fldui/flddb.cxx
sw/source/ui/fldui/flddinf.cxx
sw/source/ui/fldui/flddok.cxx
sw/source/ui/fldui/fldfunc.cxx
sw/source/ui/fldui/fldmgr.cxx
sw/source/ui/fldui/fldpage.hxx
sw/source/ui/fldui/fldref.cxx
sw/source/ui/fldui/fldvar.cxx
sw/source/ui/fldui/fldvar.hxx
sw/source/ui/fldui/fldwrap.cxx
sw/source/ui/fldui/xfldui.cxx
sw/source/ui/inc/docstdlg.hxx
sw/source/ui/shells/langhelper.cxx
sw/source/ui/shells/txtattr.cxx
sw/source/ui/shells/txtcrsr.cxx
sw/source/ui/table/tabledlg.cxx
Diffstat (limited to 'sw/source/core/text/itrcrsr.cxx')
-rw-r--r-- | sw/source/core/text/itrcrsr.cxx | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/sw/source/core/text/itrcrsr.cxx b/sw/source/core/text/itrcrsr.cxx index 5aed6230f9..9234bc1315 100644 --- a/sw/source/core/text/itrcrsr.cxx +++ b/sw/source/core/text/itrcrsr.cxx @@ -80,9 +80,9 @@ void lcl_GetCharRectInsideField( SwTxtSizeInfo& rInf, SwRect& rOrig, if ( rPor.InFldGrp() && ((SwFldPortion&)rPor).GetExp().Len() ) { - const USHORT nCharOfst = rCMS.pSpecialPos->nCharOfst; - USHORT nFldIdx = 0; - USHORT nFldLen = 0; + const sal_uInt16 nCharOfst = rCMS.pSpecialPos->nCharOfst; + sal_uInt16 nFldIdx = 0; + sal_uInt16 nFldLen = 0; const XubString* pString = 0; const SwLinePortion* pPor = &rPor; @@ -106,10 +106,10 @@ void lcl_GetCharRectInsideField( SwTxtSizeInfo& rInf, SwRect& rOrig, rOrig.Pos().X() += pPor->Width(); pPor = pPor->GetPortion(); - } while ( TRUE ); + } while ( sal_True ); OSL_ENSURE( nCharOfst >= nFldIdx, "Request of position inside field failed" ); - USHORT nLen = nCharOfst - nFldIdx + 1; + sal_uInt16 nLen = nCharOfst - nFldIdx + 1; if ( pString ) { @@ -154,7 +154,7 @@ namespace { if ( rTxtNode.AreListLevelIndentsApplicable() ) { const SwNumFmt& rNumFmt = - rTxtNode.GetNumRule()->Get( static_cast<USHORT>(rTxtNode.GetActualListLevel()) ); + rTxtNode.GetNumRule()->Get( static_cast<sal_uInt16>(rTxtNode.GetActualListLevel()) ); if ( rNumFmt.GetPositionAndSpaceMode() == SvxNumberFormat::LABEL_ALIGNMENT ) { bRet = true; @@ -346,7 +346,7 @@ void SwTxtMargin::CtorInitTxtMargin( SwTxtFrm *pNewFrm, SwTxtSizeInfo *pNewInf ) nFirst = nRight - 1; } const SvxAdjustItem& rAdjust = pFrm->GetTxtNode()->GetSwAttrSet().GetAdjust(); - nAdjust = static_cast<USHORT>(rAdjust.GetAdjust()); + nAdjust = static_cast<sal_uInt16>(rAdjust.GetAdjust()); // left is left and right is right if ( pFrm->IsRightToLeft() ) @@ -640,7 +640,7 @@ void SwTxtCursor::_GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, // For common portions (including BidiPortions) we want to add // the portion width to nX. For MultiPortions, nExtra = 0, // therefore we go to the 'else' branch and start a recursion. - const BYTE nExtra = pPor->IsMultiPortion() && + const sal_uInt8 nExtra = pPor->IsMultiPortion() && ! ((SwMultiPortion*)pPor)->IsBidi() && ! bWidth ? 0 : 1; if ( aInf.GetIdx() + pPor->GetLen() < nOfst + nExtra ) @@ -752,7 +752,7 @@ void SwTxtCursor::_GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, // of the multi-portion. xub_StrLen nOldStart = nStart; SwTwips nOldY = nY; - BYTE nOldProp = GetPropFont(); + sal_uInt8 nOldProp = GetPropFont(); nStart = aInf.GetIdx(); SwLineLayout* pOldCurr = pCurr; pCurr = &((SwMultiPortion*)pPor)->GetRoot(); @@ -761,14 +761,14 @@ void SwTxtCursor::_GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, GETGRID( GetTxtFrm()->FindPageFrm() ) const sal_Bool bHasGrid = pGrid && GetInfo().SnapToGrid(); - const USHORT nRubyHeight = bHasGrid ? + const sal_uInt16 nRubyHeight = bHasGrid ? pGrid->GetRubyHeight() : 0; if( nStart + pCurr->GetLen() <= nOfst && GetNext() && ( ! ((SwMultiPortion*)pPor)->IsRuby() || ((SwMultiPortion*)pPor)->OnTop() ) ) { - USHORT nOffset; + sal_uInt16 nOffset; // in grid mode we may only add the height of the // ruby line if ruby line is on top if ( bHasGrid && @@ -790,8 +790,8 @@ void SwTxtCursor::_GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, // temporarily set the inner line height to the // outer line height because that value is needed // for the adjustment inside the recursion - const USHORT nOldRubyHeight = pCurr->Height(); - const USHORT nOldRubyRealHeight = pCurr->GetRealHeight(); + const sal_uInt16 nOldRubyHeight = pCurr->Height(); + const sal_uInt16 nOldRubyRealHeight = pCurr->GetRealHeight(); const sal_Bool bChgHeight = ((SwMultiPortion*)pPor)->IsRuby() && bHasGrid; @@ -1066,7 +1066,7 @@ void SwTxtCursor::_GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, if( nTmpHeight < pOrig->Height() ) { nTmpAscent = nPorAscent; - nTmpHeight = USHORT( pOrig->Height() ); + nTmpHeight = sal_uInt16( pOrig->Height() ); } } if( bWidth && pPor->PrtWidth() && pPor->GetLen() && @@ -1126,7 +1126,7 @@ void SwTxtCursor::_GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, // the bidi portion if ( pLastBidiPor ) { - const BYTE nPortionLevel = pLastBidiPor->GetLevel(); + const sal_uInt8 nPortionLevel = pLastBidiPor->GetLevel(); if ( pCMS->nCursorBidiLevel >= nPortionLevel ) { @@ -1153,7 +1153,7 @@ void SwTxtCursor::_GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, } else { - const BYTE nPortionLevel = ((SwBidiPortion*)pPor)->GetLevel(); + const sal_uInt8 nPortionLevel = ((SwBidiPortion*)pPor)->GetLevel(); if ( pCMS->nCursorBidiLevel >= nPortionLevel ) { @@ -1199,7 +1199,7 @@ sal_Bool SwTxtCursor::GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, if ( bSpecialPos ) { - const BYTE nExtendRange = pCMS->pSpecialPos->nExtendRange; + const sal_uInt8 nExtendRange = pCMS->pSpecialPos->nExtendRange; OSL_ENSURE( ! pCMS->pSpecialPos->nLineOfst || SP_EXTEND_RANGE_BEFORE != nExtendRange, "LineOffset AND Number Portion?" ); @@ -1209,7 +1209,7 @@ sal_Bool SwTxtCursor::GetCharRect( SwRect* pOrig, const xub_StrLen nOfst, ++nFindOfst; // skip lines for fields which cover more than one line - for ( USHORT i = 0; i < pCMS->pSpecialPos->nLineOfst; i++ ) + for ( sal_uInt16 i = 0; i < pCMS->pSpecialPos->nLineOfst; i++ ) Next(); } @@ -1328,7 +1328,7 @@ xub_StrLen SwTxtCursor::GetCrsrOfst( SwPosition *pPos, const Point &rPoint, if ( pPor->InSpaceGrp() && nSpaceAdd ) { ((SwTxtSizeInfo&)GetInfo()).SetIdx( nCurrStart ); - nWidth = nWidth + USHORT( pPor->CalcSpacing( nSpaceAdd, GetInfo() ) ); + nWidth = nWidth + sal_uInt16( pPor->CalcSpacing( nSpaceAdd, GetInfo() ) ); } if( ( pPor->InFixMargGrp() && ! pPor->IsMarginPortion() ) || ( pPor->IsMultiPortion() && ((SwMultiPortion*)pPor)->HasTabulator() ) @@ -1372,7 +1372,7 @@ xub_StrLen SwTxtCursor::GetCrsrOfst( SwPosition *pPos, const Point &rPoint, if ( pPor->InSpaceGrp() && nSpaceAdd ) { ((SwTxtSizeInfo&)GetInfo()).SetIdx( nCurrStart ); - nWidth = nWidth + USHORT( pPor->CalcSpacing( nSpaceAdd, GetInfo() ) ); + nWidth = nWidth + sal_uInt16( pPor->CalcSpacing( nSpaceAdd, GetInfo() ) ); } if( ( pPor->InFixMargGrp() && ! pPor->IsMarginPortion() ) || @@ -1577,7 +1577,7 @@ xub_StrLen SwTxtCursor::GetCrsrOfst( SwPosition *pPos, const Point &rPoint, SwLayoutModeModifier aLayoutModeModifier( *GetInfo().GetOut() ); if ( ((SwMultiPortion*)pPor)->IsBidi() ) { - const BYTE nBidiLevel = ((SwBidiPortion*)pPor)->GetLevel(); + const sal_uInt8 nBidiLevel = ((SwBidiPortion*)pPor)->GetLevel(); aLayoutModeModifier.Modify( nBidiLevel % 2 ); } @@ -1593,7 +1593,7 @@ xub_StrLen SwTxtCursor::GetCrsrOfst( SwPosition *pPos, const Point &rPoint, if( ((SwMultiPortion*)pPor)->HasBrackets() ) { - USHORT nPreWidth = ((SwDoubleLinePortion*)pPor)->PreWidth(); + sal_uInt16 nPreWidth = ((SwDoubleLinePortion*)pPor)->PreWidth(); if ( nX > nPreWidth ) nX = nX - nPreWidth; else @@ -1605,7 +1605,7 @@ xub_StrLen SwTxtCursor::GetCrsrOfst( SwPosition *pPos, const Point &rPoint, } if( pPor->InTxtGrp() ) { - BYTE nOldProp; + sal_uInt8 nOldProp; if( GetPropFont() ) { ((SwFont*)GetFnt())->SetProportion( GetPropFont() ); @@ -1864,7 +1864,7 @@ bool SwTxtFrm::FillSelection( SwSelectionList& rSelList, const SwRect& rRect ) c if( GetDrawObjs() ) { const SwSortedObjs &rObjs = *GetDrawObjs(); - for ( USHORT i = 0; i < rObjs.Count(); ++i ) + for ( sal_uInt16 i = 0; i < rObjs.Count(); ++i ) { const SwAnchoredObject* pAnchoredObj = rObjs[i]; if( !pAnchoredObj->ISA(SwFlyFrm) ) |