diff options
Diffstat (limited to 'editeng/source')
-rwxr-xr-x | editeng/source/editeng/editdoc.hxx | 2 | ||||
-rwxr-xr-x | editeng/source/editeng/editeng.cxx | 4 | ||||
-rwxr-xr-x | editeng/source/editeng/eehtml.cxx | 4 | ||||
-rwxr-xr-x | editeng/source/editeng/impedit.hxx | 2 | ||||
-rwxr-xr-x | editeng/source/editeng/impedit2.cxx | 10 | ||||
-rw-r--r-- | editeng/source/editeng/impedit3.cxx | 5 | ||||
-rw-r--r-- | editeng/source/items/frmitems.cxx | 11 | ||||
-rwxr-xr-x | editeng/source/items/justifyitem.cxx | 58 | ||||
-rw-r--r-- | editeng/source/items/textitem.cxx | 2 | ||||
-rw-r--r-- | editeng/source/misc/svxacorr.cxx | 2 | ||||
-rw-r--r-- | editeng/source/misc/txtrange.cxx | 2 | ||||
-rwxr-xr-x | editeng/source/outliner/outleeng.hxx | 2 | ||||
-rw-r--r-- | editeng/source/outliner/outliner.cxx | 6 | ||||
-rw-r--r-- | editeng/source/outliner/outlvw.cxx | 71 | ||||
-rw-r--r-- | editeng/source/outliner/paralist.cxx | 4 | ||||
-rw-r--r-- | editeng/source/outliner/paralist.hxx | 8 | ||||
-rw-r--r-- | editeng/source/rtf/rtfitem.cxx | 175 |
17 files changed, 71 insertions, 297 deletions
diff --git a/editeng/source/editeng/editdoc.hxx b/editeng/source/editeng/editdoc.hxx index 85312b11ee..de5174738e 100755 --- a/editeng/source/editeng/editdoc.hxx +++ b/editeng/source/editeng/editdoc.hxx @@ -187,7 +187,7 @@ private: public: ItemList(); - const SfxPoolItem* FindAttrib( USHORT nWhich ); + const SfxPoolItem* FindAttrib( sal_uInt16 nWhich ); const SfxPoolItem* First(); const SfxPoolItem* Next(); size_t Count() { return aItemPool.size(); }; diff --git a/editeng/source/editeng/editeng.cxx b/editeng/source/editeng/editeng.cxx index d8bddb6abf..ef10e8bfe7 100755 --- a/editeng/source/editeng/editeng.cxx +++ b/editeng/source/editeng/editeng.cxx @@ -2440,8 +2440,8 @@ void EditEngine::DrawingText( const Point&, const XubString&, sal_uInt16, sal_uI void EditEngine::DrawingTab( const Point& /*rStartPos*/, long /*nWidth*/, const String& /*rChar*/, const SvxFont& /*rFont*/, - USHORT /*nPara*/, xub_StrLen /*nIndex*/, - BYTE /*nRightToLeft*/, bool /*bEndOfLine*/, + sal_uInt16 /*nPara*/, xub_StrLen /*nIndex*/, + sal_uInt8 /*nRightToLeft*/, bool /*bEndOfLine*/, bool /*bEndOfParagraph*/, const Color& /*rOverlineColor*/, const Color& /*rTextLineColor*/) { diff --git a/editeng/source/editeng/eehtml.cxx b/editeng/source/editeng/eehtml.cxx index c34d540188..b06d3df824 100755 --- a/editeng/source/editeng/eehtml.cxx +++ b/editeng/source/editeng/eehtml.cxx @@ -650,8 +650,8 @@ void EditHTMLParser::ImpSetStyleSheet( sal_uInt16 nHLevel ) if ( !nHLevel || ((nHLevel >= 1) && (nHLevel <= 6)) ) { SvxULSpaceItem aULSpaceItem( EE_PARA_ULSPACE ); - aULSpaceItem.SetUpper( (USHORT)OutputDevice::LogicToLogic( 42, MAP_10TH_MM, eUnit ) ); - aULSpaceItem.SetLower( (USHORT)OutputDevice::LogicToLogic( 35, MAP_10TH_MM, eUnit ) ); + aULSpaceItem.SetUpper( (sal_uInt16)OutputDevice::LogicToLogic( 42, MAP_10TH_MM, eUnit ) ); + aULSpaceItem.SetLower( (sal_uInt16)OutputDevice::LogicToLogic( 35, MAP_10TH_MM, eUnit ) ); aItems.Put( aULSpaceItem ); } } diff --git a/editeng/source/editeng/impedit.hxx b/editeng/source/editeng/impedit.hxx index 45b64cb328..327ecdbba3 100755 --- a/editeng/source/editeng/impedit.hxx +++ b/editeng/source/editeng/impedit.hxx @@ -990,7 +990,7 @@ public: sal_Int32 GetSpaceBeforeAndMinLabelWidth( const ContentNode *pNode, sal_Int32 *pnSpaceBefore = 0, sal_Int32 *pnMinLabelWidth = 0 ) const; const SvxLRSpaceItem& GetLRSpaceItem( ContentNode* pNode ); - SvxAdjust GetJustification( USHORT nPara ) const; + SvxAdjust GetJustification( sal_uInt16 nPara ) const; SvxCellJustifyMethod GetJustifyMethod( sal_uInt16 nPara ) const; SvxCellVerJustify GetVerJustification( sal_uInt16 nPara ) const; diff --git a/editeng/source/editeng/impedit2.cxx b/editeng/source/editeng/impedit2.cxx index 4a6bb9ce0c..dd133e4a12 100755 --- a/editeng/source/editeng/impedit2.cxx +++ b/editeng/source/editeng/impedit2.cxx @@ -1675,7 +1675,7 @@ void ImpEditEngine::InitScriptTypes( sal_uInt16 nPara ) { ParaPortion* pParaPortion = GetParaPortions().SaveGetObject( nPara ); ScriptTypePosInfos& rTypes = pParaPortion->aScriptInfos; - rTypes.Remove( 0, rTypes.Count() ); + rTypes.clear(); ContentNode* pNode = pParaPortion->GetNode(); if ( pNode->Len() ) @@ -2088,14 +2088,14 @@ SvxAdjust ImpEditEngine::GetJustification( sal_uInt16 nPara ) const return eJustification; } -SvxCellJustifyMethod ImpEditEngine::GetJustifyMethod( USHORT nPara ) const +SvxCellJustifyMethod ImpEditEngine::GetJustifyMethod( sal_uInt16 nPara ) const { const SvxJustifyMethodItem& rItem = static_cast<const SvxJustifyMethodItem&>( GetParaAttrib(nPara, EE_PARA_JUST_METHOD)); return static_cast<SvxCellJustifyMethod>(rItem.GetEnumValue()); } -SvxCellVerJustify ImpEditEngine::GetVerJustification( USHORT nPara ) const +SvxCellVerJustify ImpEditEngine::GetVerJustification( sal_uInt16 nPara ) const { const SvxVerJustifyItem& rItem = static_cast<const SvxVerJustifyItem&>( GetParaAttrib(nPara, EE_PARA_VER_JUST)); @@ -2539,8 +2539,8 @@ void ImpEditEngine::ImpRemoveParagraph( sal_uInt16 nPara ) } } -EditPaM ImpEditEngine::AutoCorrect( const EditSelection& rCurSel, xub_Unicode c, - bool bOverwrite, Window* pFrameWin ) +EditPaM ImpEditEngine::AutoCorrect( const EditSelection& rCurSel, xub_Unicode c, + sal_Bool bOverwrite, Window* pFrameWin ) { EditSelection aSel( rCurSel ); #ifndef SVX_LIGHT diff --git a/editeng/source/editeng/impedit3.cxx b/editeng/source/editeng/impedit3.cxx index 170c05af01..91884d49f3 100644 --- a/editeng/source/editeng/impedit3.cxx +++ b/editeng/source/editeng/impedit3.cxx @@ -2013,7 +2013,7 @@ void ImpEditEngine::ImpAdjustBlocks( ParaPortion* pParaPortion, EditLine* pLine, { EditPaM aPaM( pNode, nChar+1 ); LanguageType eLang = GetLanguage(aPaM); - USHORT nScript = GetScriptType(aPaM); + sal_uInt16 nScript = GetScriptType(aPaM); if ( MsLangId::getPrimaryLanguage( eLang) == LANGUAGE_ARABIC_PRIMARY_ONLY ) // Arabic script is handled later. continue; @@ -2083,13 +2083,12 @@ void ImpEditEngine::ImpAdjustBlocks( ParaPortion* pParaPortion, EditLine* pLine, // Letztes Zeichen wird schon nicht mehr beachtet... for ( sal_uInt16 n = 0; n < aPositions.Count(); n++ ) { - USHORT nChar = aPositions[n]; + sal_uInt16 nChar = aPositions[n]; if ( nChar < nLastChar ) { sal_uInt16 nPortionStart, nPortion; nPortion = pParaPortion->GetTextPortions().FindPortion( nChar, nPortionStart, true ); TextPortion* pLastPortion = pParaPortion->GetTextPortions()[ nPortion ]; - USHORT nPortionEnd = nPortionStart + pLastPortion->GetLen(); // Die Breite der Portion: pLastPortion->GetSize().Width() += nMore4Everyone; diff --git a/editeng/source/items/frmitems.cxx b/editeng/source/items/frmitems.cxx index 2730b00c93..d5042e8065 100644 --- a/editeng/source/items/frmitems.cxx +++ b/editeng/source/items/frmitems.cxx @@ -1563,10 +1563,10 @@ void SvxShadowItem::SetEnumValue( sal_uInt16 nVal ) SvxBorderLine::SvxBorderLine( const Color *pCol, sal_uInt16 nOut, sal_uInt16 nIn, sal_uInt16 nDist, SvxBorderStyle nStyle ) -: nOutWidth( nOut ) +: m_nStyle( nStyle ) +, nOutWidth( nOut ) , nInWidth ( nIn ) , nDistance( nDist ) -, m_nStyle( nStyle ) { if ( pCol ) aColor = *pCol; @@ -1935,7 +1935,8 @@ sal_Bool SvxBoxItem::LineToSvxLine(const ::com::sun::star::table::BorderLine& rL return lcl_lineToSvxLine(rLine, rSvxLine, bConvert); } -bool SvxBoxItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) +sal_Bool +SvxBoxItem::LineToSvxLine(const ::com::sun::star::table::BorderLine2& rLine, SvxBorderLine& rSvxLine, sal_Bool bConvert) { const bool bRet(lcl_lineToSvxLine(rLine, rSvxLine, bConvert)); @@ -1983,7 +1984,7 @@ lcl_extractBorderLine(const uno::Any& rAny, table::BorderLine2& rLine) template<typename Item> bool -lcl_setLine(const uno::Any& rAny, Item& rItem, USHORT nLine, const bool bConvert) +lcl_setLine(const uno::Any& rAny, Item& rItem, sal_uInt16 nLine, const bool bConvert) { bool bDone = false; table::BorderLine2 aBorderLine; @@ -1999,7 +2000,7 @@ lcl_setLine(const uno::Any& rAny, Item& rItem, USHORT nLine, const bool bConvert } -bool SvxBoxItem::PutValue( const uno::Any& rVal, BYTE nMemberId ) +bool SvxBoxItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) { bool bConvert = 0!=(nMemberId&CONVERT_TWIPS); sal_uInt16 nLine = BOX_LINE_TOP; diff --git a/editeng/source/items/justifyitem.cxx b/editeng/source/items/justifyitem.cxx index 1256c4b77d..c8f4c7c3e1 100755 --- a/editeng/source/items/justifyitem.cxx +++ b/editeng/source/items/justifyitem.cxx @@ -52,14 +52,14 @@ using namespace ::com::sun::star; -SvxHorJustifyItem::SvxHorJustifyItem( const USHORT nId ) : - SfxEnumItem( nId, (USHORT)SVX_HOR_JUSTIFY_STANDARD ) +SvxHorJustifyItem::SvxHorJustifyItem( const sal_uInt16 nId ) : + SfxEnumItem( nId, (sal_uInt16)SVX_HOR_JUSTIFY_STANDARD ) { } SvxHorJustifyItem::SvxHorJustifyItem( const SvxCellHorJustify eJustify, - const USHORT nId ) : - SfxEnumItem( nId, (USHORT)eJustify ) + const sal_uInt16 nId ) : + SfxEnumItem( nId, (sal_uInt16)eJustify ) { } @@ -155,7 +155,7 @@ bool SvxHorJustifyItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) case table::CellHoriJustify_REPEAT: eSvx = SVX_HOR_JUSTIFY_REPEAT; break; default: ; //prevent warning } - SetValue( (USHORT)eSvx ); + SetValue( (sal_uInt16)eSvx ); } break; case MID_HORJUST_ADJUST: @@ -175,14 +175,14 @@ bool SvxHorJustifyItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) case style::ParagraphAdjust_BLOCK: eSvx = SVX_HOR_JUSTIFY_BLOCK; break; case style::ParagraphAdjust_CENTER: eSvx = SVX_HOR_JUSTIFY_CENTER; break; } - SetValue( (USHORT)eSvx ); + SetValue( (sal_uInt16)eSvx ); } } return true; } -XubString SvxHorJustifyItem::GetValueText( USHORT nVal ) const +XubString SvxHorJustifyItem::GetValueText( sal_uInt16 nVal ) const { DBG_ASSERT( nVal <= SVX_HOR_JUSTIFY_REPEAT, "enum overflow!" ); return EE_RESSTR(RID_SVXITEMS_HORJUST_STANDARD + nVal); @@ -195,28 +195,28 @@ SfxPoolItem* SvxHorJustifyItem::Clone( SfxItemPool* ) const } -SfxPoolItem* SvxHorJustifyItem::Create( SvStream& rStream, USHORT ) const +SfxPoolItem* SvxHorJustifyItem::Create( SvStream& rStream, sal_uInt16 ) const { - USHORT nVal; + sal_uInt16 nVal; rStream >> nVal; return new SvxHorJustifyItem( (SvxCellHorJustify)nVal, Which() ); } -USHORT SvxHorJustifyItem::GetValueCount() const +sal_uInt16 SvxHorJustifyItem::GetValueCount() const { return SVX_HOR_JUSTIFY_REPEAT + 1; // Last Enum value + 1 } -SvxVerJustifyItem::SvxVerJustifyItem( const USHORT nId ) : - SfxEnumItem( nId, (USHORT)SVX_VER_JUSTIFY_STANDARD ) +SvxVerJustifyItem::SvxVerJustifyItem( const sal_uInt16 nId ) : + SfxEnumItem( nId, (sal_uInt16)SVX_VER_JUSTIFY_STANDARD ) { } SvxVerJustifyItem::SvxVerJustifyItem( const SvxCellVerJustify eJustify, - const USHORT nId ) : - SfxEnumItem( nId, (USHORT)eJustify ) + const sal_uInt16 nId ) : + SfxEnumItem( nId, (sal_uInt16)eJustify ) { } @@ -301,7 +301,7 @@ bool SvxVerJustifyItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) case style::VerticalAlignment_BOTTOM: eSvx = SVX_VER_JUSTIFY_BOTTOM; break; default:; } - SetValue( (USHORT)eSvx ); + SetValue( (sal_uInt16)eSvx ); break; } default: @@ -319,7 +319,7 @@ bool SvxVerJustifyItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) case table::CellVertJustify2::BLOCK: eSvx = SVX_VER_JUSTIFY_BLOCK; break; default: ; //prevent warning } - SetValue( (USHORT)eSvx ); + SetValue( (sal_uInt16)eSvx ); break; } } @@ -328,7 +328,7 @@ bool SvxVerJustifyItem::PutValue( const uno::Any& rVal, sal_uInt8 nMemberId ) } -XubString SvxVerJustifyItem::GetValueText( USHORT nVal ) const +XubString SvxVerJustifyItem::GetValueText( sal_uInt16 nVal ) const { DBG_ASSERT( nVal <= SVX_VER_JUSTIFY_BOTTOM, "enum overflow!" ); return EE_RESSTR(RID_SVXITEMS_VERJUST_STANDARD + nVal); @@ -341,29 +341,29 @@ SfxPoolItem* SvxVerJustifyItem::Clone( SfxItemPool* ) const } -SfxPoolItem* SvxVerJustifyItem::Create( SvStream& rStream, USHORT ) const +SfxPoolItem* SvxVerJustifyItem::Create( SvStream& rStream, sal_uInt16 ) const { - USHORT nVal; + sal_uInt16 nVal; rStream >> nVal; return new SvxVerJustifyItem( (SvxCellVerJustify)nVal, Which() ); } -USHORT SvxVerJustifyItem::GetValueCount() const +sal_uInt16 SvxVerJustifyItem::GetValueCount() const { return SVX_VER_JUSTIFY_BOTTOM + 1; // Last Enum value + 1 } -SvxJustifyMethodItem::SvxJustifyMethodItem( const USHORT nId ) : - SfxEnumItem( nId, (USHORT)SVX_JUSTIFY_METHOD_AUTO ) +SvxJustifyMethodItem::SvxJustifyMethodItem( const sal_uInt16 nId ) : + SfxEnumItem( nId, (sal_uInt16)SVX_JUSTIFY_METHOD_AUTO ) { } SvxJustifyMethodItem::SvxJustifyMethodItem( const SvxCellJustifyMethod eJustify, - const USHORT nId ) : - SfxEnumItem( nId, (USHORT)eJustify ) + const sal_uInt16 nId ) : + SfxEnumItem( nId, (sal_uInt16)eJustify ) { } @@ -421,12 +421,12 @@ bool SvxJustifyMethodItem::PutValue( const uno::Any& rVal, sal_uInt8 /*nMemberId break; default:; } - SetValue(static_cast<USHORT>(eSvx)); + SetValue(static_cast<sal_uInt16>(eSvx)); return true; } -XubString SvxJustifyMethodItem::GetValueText( USHORT nVal ) const +XubString SvxJustifyMethodItem::GetValueText( sal_uInt16 nVal ) const { DBG_ASSERT( nVal <= SVX_VER_JUSTIFY_BOTTOM, "enum overflow!" ); return EE_RESSTR(RID_SVXITEMS_JUSTMETHOD_AUTO + nVal); @@ -439,15 +439,15 @@ SfxPoolItem* SvxJustifyMethodItem::Clone( SfxItemPool* ) const } -SfxPoolItem* SvxJustifyMethodItem::Create( SvStream& rStream, USHORT ) const +SfxPoolItem* SvxJustifyMethodItem::Create( SvStream& rStream, sal_uInt16 ) const { - USHORT nVal; + sal_uInt16 nVal; rStream >> nVal; return new SvxJustifyMethodItem( (SvxCellJustifyMethod)nVal, Which() ); } -USHORT SvxJustifyMethodItem::GetValueCount() const +sal_uInt16 SvxJustifyMethodItem::GetValueCount() const { return SVX_JUSTIFY_METHOD_DISTRIBUTE + 1; // Last Enum value + 1 } diff --git a/editeng/source/items/textitem.cxx b/editeng/source/items/textitem.cxx index 280f427e7a..d6a8f01aba 100644 --- a/editeng/source/items/textitem.cxx +++ b/editeng/source/items/textitem.cxx @@ -614,7 +614,7 @@ int SvxPostureItem::HasBoolValue() const // ----------------------------------------------------------------------- -BOOL SvxPostureItem::GetBoolValue() const +sal_Bool SvxPostureItem::GetBoolValue() const { return ( (FontItalic)GetValue() >= ITALIC_OBLIQUE ); } diff --git a/editeng/source/misc/svxacorr.cxx b/editeng/source/misc/svxacorr.cxx index 052b4b4688..a73452059b 100644 --- a/editeng/source/misc/svxacorr.cxx +++ b/editeng/source/misc/svxacorr.cxx @@ -669,7 +669,7 @@ sal_Bool SvxAutoCorrect::FnAddNonBrkSpace( ; if(INetURLObject::CompareProtocolScheme(rTxt.Copy(nSttWdPos + (bWasWordDelim ? 1 : 0), nEndPos - nSttWdPos + 1)) != INET_PROT_NOT_VALID) { - return FALSE; + return sal_False; } diff --git a/editeng/source/misc/txtrange.cxx b/editeng/source/misc/txtrange.cxx index 0204d60f42..43a1f44cab 100644 --- a/editeng/source/misc/txtrange.cxx +++ b/editeng/source/misc/txtrange.cxx @@ -305,7 +305,7 @@ void SvxBoundArgs::NoteRange( sal_Bool bToggle ) aBoolArr.erase( aBoolArr.begin() + nMaxIdx, aBoolArr.begin() + (nMaxIdx + nDiff) ); } DBG_ASSERT( nMaxIdx < aBoolArr.size(), "NoteRange: Too much deleted" ); - aBoolArr[ nMaxIdx ] ^= bToggle; + aBoolArr[ nMaxIdx ] = aBoolArr[ nMaxIdx ] ^ bToggle; } } diff --git a/editeng/source/outliner/outleeng.hxx b/editeng/source/outliner/outleeng.hxx index b6ddc7bd11..cbe254c845 100755 --- a/editeng/source/outliner/outleeng.hxx +++ b/editeng/source/outliner/outleeng.hxx @@ -68,7 +68,7 @@ public: virtual void DrawingTab( const Point& rStartPos, long nWidth, const String& rChar, - const SvxFont& rFont, USHORT nPara, xub_StrLen nIndex, BYTE nRightToLeft, + const SvxFont& rFont, sal_uInt16 nPara, xub_StrLen nIndex, sal_uInt8 nRightToLeft, bool bEndOfLine, bool bEndOfParagraph, const Color& rOverlineColor, diff --git a/editeng/source/outliner/outliner.cxx b/editeng/source/outliner/outliner.cxx index 67988ba596..3e0cc204fc 100644 --- a/editeng/source/outliner/outliner.cxx +++ b/editeng/source/outliner/outliner.cxx @@ -922,7 +922,7 @@ Font Outliner::ImpCalcBulletFont( sal_uInt16 nPara ) const } // Use original scale... - USHORT nStretchX, nStretchY; + sal_uInt16 nStretchX, nStretchY; const_cast<Outliner*>(this)->GetGlobalCharStretching(nStretchX, nStretchY); sal_uInt16 nScale = pFmt->GetBulletRelSize() * nStretchY / 100; @@ -1144,7 +1144,7 @@ void Outliner::InvalidateBullet( Paragraph* /*pPara*/, sal_uLong nPara ) for ( size_t i = 0, n = aViewList.size(); i < n; ++i ) { OutlinerView* pView = aViewList[ i ]; - Point aPos( pView->pEditView->GetWindowPosTopLeft((USHORT)nPara ) ); + Point aPos( pView->pEditView->GetWindowPosTopLeft((sal_uInt16)nPara ) ); Rectangle aRect( pView->GetOutputArea() ); aRect.Right() = aPos.X(); aRect.Top() = aPos.Y(); @@ -1815,7 +1815,7 @@ void Outliner::DrawingText( const Point& rStartPos, const XubString& rText, sal_ } void Outliner::DrawingTab( const Point& rStartPos, long nWidth, const String& rChar, const SvxFont& rFont, - USHORT nPara, xub_StrLen nIndex, BYTE nRightToLeft, bool bEndOfLine, bool bEndOfParagraph, + sal_uInt16 nPara, xub_StrLen nIndex, sal_uInt8 nRightToLeft, bool bEndOfLine, bool bEndOfParagraph, const Color& rOverlineColor, const Color& rTextLineColor) { if(aDrawPortionHdl.IsSet()) diff --git a/editeng/source/outliner/outlvw.cxx b/editeng/source/outliner/outlvw.cxx index 217888fc06..7e832b7304 100644 --- a/editeng/source/outliner/outlvw.cxx +++ b/editeng/source/outliner/outlvw.cxx @@ -269,11 +269,8 @@ sal_Bool OutlinerView::PostKeyEvent( const KeyEvent& rKEvt, Window* pFrameWin ) } } -<<<<<<< HEAD - return bKeyProcessed ? TRUE : pEditView->PostKeyEvent( rKEvt, pFrameWin ); -======= - return bKeyProcessed ? sal_True : pEditView->PostKeyEvent( rKEvt ); ->>>>>>> ooo/DEV300_m101 + return bKeyProcessed ? sal_True : pEditView->PostKeyEvent( rKEvt, pFrameWin ); + } @@ -321,11 +318,7 @@ sal_uLong OutlinerView::ImpCheckMousePos(const Point& rPosPix, MouseTarget& reTa return nPara; } -<<<<<<< HEAD -BOOL OutlinerView::MouseMove( const MouseEvent& rMEvt ) -======= -sal_Bool __EXPORT OutlinerView::MouseMove( const MouseEvent& rMEvt ) ->>>>>>> ooo/DEV300_m101 +sal_Bool OutlinerView::MouseMove( const MouseEvent& rMEvt ) { DBG_CHKTHIS(OutlinerView,0); @@ -342,11 +335,7 @@ sal_Bool __EXPORT OutlinerView::MouseMove( const MouseEvent& rMEvt ) } -<<<<<<< HEAD -BOOL OutlinerView::MouseButtonDown( const MouseEvent& rMEvt ) -======= -sal_Bool __EXPORT OutlinerView::MouseButtonDown( const MouseEvent& rMEvt ) ->>>>>>> ooo/DEV300_m101 +sal_Bool OutlinerView::MouseButtonDown( const MouseEvent& rMEvt ) { DBG_CHKTHIS(OutlinerView,0); if ( ( pOwner->ImplGetOutlinerMode() == OUTLINERMODE_TEXTOBJECT ) || pEditView->GetEditEngine()->IsInSelectionMode() ) @@ -370,13 +359,8 @@ sal_Bool __EXPORT OutlinerView::MouseButtonDown( const MouseEvent& rMEvt ) sal_uLong nEndPara = nPara; if ( bHasChilds && pOwner->pParaList->HasVisibleChilds(pPara) ) nEndPara += pOwner->pParaList->GetChildCount( pPara ); -<<<<<<< HEAD - // The selection is inverted, so that EditEngine does not scroll - ESelection aSel((USHORT)nEndPara, 0xffff,(USHORT)nPara, 0 ); -======= - // umgekehrt rum selektieren, damit EditEngine nicht scrollt + // The selection is inverted, so that EditEngine does not scroll ESelection aSel((sal_uInt16)nEndPara, 0xffff,(sal_uInt16)nPara, 0 ); ->>>>>>> ooo/DEV300_m101 pEditView->SetSelection( aSel ); } else if( rMEvt.GetClicks() == 2 && bHasChilds ) @@ -402,11 +386,7 @@ sal_Bool __EXPORT OutlinerView::MouseButtonDown( const MouseEvent& rMEvt ) } -<<<<<<< HEAD -BOOL OutlinerView::MouseButtonUp( const MouseEvent& rMEvt ) -======= -sal_Bool __EXPORT OutlinerView::MouseButtonUp( const MouseEvent& rMEvt ) ->>>>>>> ooo/DEV300_m101 +sal_Bool OutlinerView::MouseButtonUp( const MouseEvent& rMEvt ) { DBG_CHKTHIS(OutlinerView,0); if ( ( pOwner->ImplGetOutlinerMode() == OUTLINERMODE_TEXTOBJECT ) || pEditView->GetEditEngine()->IsInSelectionMode() ) @@ -570,21 +550,11 @@ void OutlinerView::SetAttribs( const SfxItemSet& rAttrs ) pEditView->SetAttribs( rAttrs ); -<<<<<<< HEAD // Update Bullet text - for( USHORT nPara= aSel.nStartPara; nPara <= aSel.nEndPara; nPara++ ) - { - pOwner->ImplCheckNumBulletItem( nPara ); - // update following paras as well, numbering depends on - // previous paras - pOwner->ImplCalcBulletText( nPara, TRUE, FALSE ); -======= - // Bullet-Texte aktualisieren for( sal_uInt16 nPara= aSel.nStartPara; nPara <= aSel.nEndPara; nPara++ ) { pOwner->ImplCheckNumBulletItem( nPara ); pOwner->ImplCalcBulletText( nPara, sal_False, sal_False ); ->>>>>>> ooo/DEV300_m101 if( !pOwner->IsInUndo() && pOwner->IsUndoEnabled() ) pOwner->InsertUndo( new OutlinerUndoCheckPara( pOwner, nPara ) ); @@ -739,19 +709,8 @@ void OutlinerView::Indent( short nDiff ) } } -<<<<<<< HEAD - USHORT nParas = (USHORT)pOwner->pParaList->GetParagraphCount(); - for ( USHORT n = aSel.nEndPara+1; n < nParas; n++ ) -======= - // MT 19.08.99: War mal fuer Optimierung (outliner.cxx#1.193), - // hat aber zu zuviel Wartungsaufwand / doppelten Funktionen gefuehrt - // und zu wenig gebracht: - // pOwner->ImpSetBulletTextsFrom( aSel.nStartPara+1, nMinDepth ); - // Wird jetzt direkt in Schleife mit ImplCalcBulletText() erledigt. - // Jetzt fehlen nur noch die folgenden Ansaetze, die davon betroffen sind. sal_uInt16 nParas = (sal_uInt16)pOwner->pParaList->GetParagraphCount(); for ( sal_uInt16 n = aSel.nEndPara+1; n < nParas; n++ ) ->>>>>>> ooo/DEV300_m101 { Paragraph* pPara = pOwner->pParaList->GetParagraph( n ); if ( pPara->GetDepth() < nMinDepth ) @@ -1194,13 +1153,8 @@ sal_uInt16 OutlinerView::ImpCalcSelectedPages( sal_Bool bIncludeFirstSelected ) sal_uInt16 nFirstPage = 0xFFFF; sal_uInt16 nStartPara = aSel.nStartPara; if ( !bIncludeFirstSelected ) -<<<<<<< HEAD nStartPara++; // All paragraphs after StartPara will be deleted - for ( USHORT nPara = nStartPara; nPara <= aSel.nEndPara; nPara++ ) -======= - nStartPara++; // alle nach StartPara kommenden Absaetze werden geloescht for ( sal_uInt16 nPara = nStartPara; nPara <= aSel.nEndPara; nPara++ ) ->>>>>>> ooo/DEV300_m101 { Paragraph* pPara = pOwner->pParaList->GetParagraph( nPara ); DBG_ASSERT(pPara, "ImpCalcSelectedPages: invalid Selection? "); @@ -1262,14 +1216,8 @@ void OutlinerView::ToggleBullets() // #i100014# // It is not a good idea to substract 1 from a count and cast the result -<<<<<<< HEAD - // to USHORT without check, if the count is 0. - USHORT nParaCount = (USHORT) (pOwner->pParaList->GetParagraphCount()); -======= // to sal_uInt16 without check, if the count is 0. sal_uInt16 nParaCount = (sal_uInt16) (pOwner->pParaList->GetParagraphCount()); - // <-- ->>>>>>> ooo/DEV300_m101 pOwner->ImplCheckParagraphs( aSel.nStartPara, nParaCount ); pOwner->pEditEngine->QuickMarkInvalid( ESelection( aSel.nStartPara, 0, nParaCount, 0 ) ); @@ -1301,14 +1249,9 @@ void OutlinerView::EnableBullets() // #i100014# // It is not a good idea to substract 1 from a count and cast the result -<<<<<<< HEAD - // to USHORT without check, if the count is 0. - USHORT nParaCount = (USHORT) (pOwner->pParaList->GetParagraphCount()); -======= // to sal_uInt16 without check, if the count is 0. sal_uInt16 nParaCount = (sal_uInt16) (pOwner->pParaList->GetParagraphCount()); - // <-- ->>>>>>> ooo/DEV300_m101 + pOwner->ImplCheckParagraphs( aSel.nStartPara, nParaCount ); pOwner->pEditEngine->QuickMarkInvalid( ESelection( aSel.nStartPara, 0, nParaCount, 0 ) ); diff --git a/editeng/source/outliner/paralist.cxx b/editeng/source/outliner/paralist.cxx index 8e35263d83..c646710c4d 100644 --- a/editeng/source/outliner/paralist.cxx +++ b/editeng/source/outliner/paralist.cxx @@ -139,14 +139,14 @@ void ParagraphList::Append( Paragraph* pPara) maEntries.push_back(pPara); } -void ParagraphList::Insert( Paragraph* pPara, ULONG nAbsPos) +void ParagraphList::Insert( Paragraph* pPara, sal_uLong nAbsPos) { OSL_ASSERT(nAbsPos != ULONG_MAX && nAbsPos <= maEntries.size()); maEntries.insert(maEntries.begin()+nAbsPos,pPara); } -void ParagraphList::Remove( ULONG nPara ) +void ParagraphList::Remove( sal_uLong nPara ) { OSL_ASSERT(nPara < maEntries.size()); diff --git a/editeng/source/outliner/paralist.hxx b/editeng/source/outliner/paralist.hxx index 8fa8db965d..f95ee37fd4 100644 --- a/editeng/source/outliner/paralist.hxx +++ b/editeng/source/outliner/paralist.hxx @@ -45,7 +45,7 @@ public: return maEntries.size(); } - Paragraph* GetParagraph( ULONG nPos ) const + Paragraph* GetParagraph( sal_uLong nPos ) const { return nPos < maEntries.size() ? maEntries[nPos] : NULL; } @@ -54,9 +54,9 @@ public: sal_uLong GetVisPos( Paragraph* pParagraph ) const; void Append( Paragraph *pPara); - void Insert( Paragraph* pPara, ULONG nAbsPos); - void Remove( ULONG nPara ); - void MoveParagraphs( ULONG nStart, ULONG nDest, ULONG nCount ); + void Insert( Paragraph* pPara, sal_uLong nAbsPos); + void Remove( sal_uLong nPara ); + void MoveParagraphs( sal_uLong nStart, sal_uLong nDest, sal_uLong nCount ); Paragraph* NextVisible( Paragraph* ) const; Paragraph* PrevVisible( Paragraph* ) const; diff --git a/editeng/source/rtf/rtfitem.cxx b/editeng/source/rtf/rtfitem.cxx index 3736c16f10..64a36aa426 100644 --- a/editeng/source/rtf/rtfitem.cxx +++ b/editeng/source/rtf/rtfitem.cxx @@ -217,15 +217,9 @@ void SvxRTFParser::SetScriptAttr( RTF_CharTypeDef eType, SfxItemSet& rSet, void SvxRTFParser::ReadAttr( int nToken, SfxItemSet* pSet ) { -<<<<<<< HEAD DBG_ASSERT( pSet, "A SfxItemSet has to be provided as argument!" ); - int bFirstToken = TRUE, bWeiter = TRUE; - USHORT nStyleNo = 0; // default -======= - DBG_ASSERT( pSet, "Es muss ein SfxItemSet uebergeben werden!" ); int bFirstToken = sal_True, bWeiter = sal_True; sal_uInt16 nStyleNo = 0; // default ->>>>>>> ooo/DEV300_m101 FontUnderline eUnderline; FontUnderline eOverline; FontEmphasisMark eEmphasis; @@ -307,53 +301,15 @@ void SvxRTFParser::ReadAttr( int nToken, SfxItemSet* pSet ) } else { -<<<<<<< HEAD - nStyleNo = -1 == nTokenValue ? 0 : USHORT(nTokenValue); - // Set the StyleNumber for the current style on - // the attribute stack - SvxRTFItemStackType* pAkt = aAttrStack.Top(); -======= nStyleNo = -1 == nTokenValue ? 0 : sal_uInt16(nTokenValue); // setze am akt. auf dem AttrStack stehenden Style die // StyleNummer SvxRTFItemStackType* pAkt = aAttrStack.empty() ? 0 : aAttrStack.back(); ->>>>>>> ooo/DEV300_m101 if( !pAkt ) break; pAkt->nStyleNo = sal_uInt16( nStyleNo ); -<<<<<<< HEAD -======= -#if 0 -// JP 05.09.95: zuruecksetzen der Style-Attribute fuehrt nur zu Problemen. -// Es muss reichen, wenn das ueber pard/plain erfolgt -// ansonsten Bugdoc 15304.rtf - nach nur "\pard" falscher Font !! - - SvxRTFStyleType* pStyle = aStyleTbl.Get( pAkt->nStyleNo ); - if( pStyle && pStyle->aAttrSet.Count() ) - { - //JP 07.07.95: - // alle Attribute, die in der Vorlage gesetzt werden - // auf defaults setzen. In RTF werden die Attribute - // der Vorlage danach ja wiederholt. - // WICHTIG: Attribute die in der Vorlage definiert - // sind, werden zurueckgesetzt !!!! - // pAkt->aAttrSet.Put( pStyle->aAttrSet ); - - SfxItemIter aIter( pStyle->aAttrSet ); - SfxItemPool* pPool = pStyle->aAttrSet.GetPool(); - sal_uInt16 nWh = aIter.GetCurItem()->Which(); - while( sal_True ) - { - pAkt->aAttrSet.Put( pPool->GetDefaultItem( nWh )); - if( aIter.IsAtEnd() ) - break; - nWh = aIter.NextItem()->Which(); - } - } -#endif ->>>>>>> ooo/DEV300_m101 } break; @@ -505,13 +461,8 @@ void SvxRTFParser::ReadAttr( int nToken, SfxItemSet* pSet ) nTokenValue = short( 100L * aLSpace.GetLineHeight() / long( nTokenValue ) ); -<<<<<<< HEAD if( nTokenValue > 200 ) // Data value for PropLnSp nTokenValue = 200; // is one BYTE !!! -======= - if( nTokenValue > 200 ) // Datenwert fuer PropLnSp - nTokenValue = 200; // ist ein sal_uInt8 !!! ->>>>>>> ooo/DEV300_m101 aLSpace.SetPropLineSpace( (const sal_uInt8)nTokenValue ); aLSpace.GetLineSpaceRule() = SVX_LINE_SPACE_AUTO; @@ -1011,9 +962,7 @@ ATTR_SETOVERLINE: break; //#i12501# While cb is clearly documented in the rtf spec, word //doesn't accept it at all -<<<<<<< HEAD - -======= +#if 0 case RTF_CB: if( PLAINID->nBgColor ) { @@ -1022,7 +971,7 @@ ATTR_SETOVERLINE: } break; #endif ->>>>>>> ooo/DEV300_m101 + case RTF_LANG: if( PLAINID->nLanguage ) { @@ -1187,13 +1136,8 @@ ATTR_SETEMPHASIS: case RTF_SWG_ESCPROP: { -<<<<<<< HEAD // Store percentage change! - BYTE nProp = BYTE( nTokenValue / 100 ); -======= - // prozentuale Veraenderung speichern ! sal_uInt8 nProp = sal_uInt8( nTokenValue / 100 ); ->>>>>>> ooo/DEV300_m101 short nEsc = 0; if( 1 == ( nTokenValue % 100 )) // Recognize own auto-flags! @@ -1250,10 +1194,6 @@ ATTR_SETEMPHASIS: if( RTF_SHDW_FCOL != GetNextToken() ) break; -<<<<<<< HEAD -======= -// sal_uInt16 nFillCol = sal_uInt16( nTokenValue ); ->>>>>>> ooo/DEV300_m101 Color aColor = GetColor( nCol ); @@ -1351,35 +1291,6 @@ ATTR_SETEMPHASIS: } bFirstToken = sal_False; } -<<<<<<< HEAD -======= - -/* - // teste Attribute gegen ihre Styles - if( IsChkStyleAttr() && pSet->Count() && !pInsPos->GetCntIdx() ) - { - SvxRTFStyleType* pStyle = aStyleTbl.Get( nStyleNo ); - if( pStyle && pStyle->aAttrSet.Count() ) - { - // alle Attribute, die schon vom Style definiert sind, aus dem - // akt. Set entfernen - const SfxPoolItem* pItem; - SfxItemIter aIter( *pSet ); - sal_uInt16 nWhich = aIter.GetCurItem()->Which(); - while( sal_True ) - { - if( SFX_ITEM_SET == pStyle->aAttrSet.GetItemState( - nWhich, sal_False, &pItem ) && *pItem == *aIter.GetCurItem()) - pSet->ClearItem( nWhich ); // loeschen - - if( aIter.IsAtEnd() ) - break; - nWhich = aIter.NextItem()->Which(); - } - } - } -*/ ->>>>>>> ooo/DEV300_m101 } void SvxRTFParser::ReadTabAttr( int nToken, SfxItemSet& rSet ) @@ -1432,27 +1343,16 @@ void SvxRTFParser::ReadTabAttr( int nToken, SfxItemSet& rSet ) nSkip = -2; else { -<<<<<<< HEAD - aTabStop.GetDecimal() = BYTE(nTokenValue & 0xff); - aTabStop.GetFill() = BYTE((nTokenValue >> 8) & 0xff); - // overwrite the closing parenthesis -======= aTabStop.GetDecimal() = sal_uInt8(nTokenValue & 0xff); aTabStop.GetFill() = sal_uInt8((nTokenValue >> 8) & 0xff); - // ueberlese noch die schliessende Klammer ->>>>>>> ooo/DEV300_m101 + // overwrite the closing parenthesis if (bMethodOwnsToken) GetNextToken(); } if( nSkip ) { -<<<<<<< HEAD SkipToken( nSkip ); // Ignore back again - bWeiter = FALSE; -======= - SkipToken( nSkip ); // Ignore wieder zurueck bWeiter = sal_False; ->>>>>>> ooo/DEV300_m101 } } break; @@ -1510,13 +1410,8 @@ void SvxRTFParser::ReadBorderAttr( int nToken, SfxItemSet& rSet, if( SFX_ITEM_SET == rSet.GetItemState( PARDID->nBox, sal_False, &pItem ) ) aAttr = *(SvxBoxItem*)pItem; -<<<<<<< HEAD SvxBorderLine aBrd( 0, DEF_LINE_WIDTH_0, 0, 0 ); // simple lines - int bWeiter = TRUE, nBorderTyp = 0; -======= - SvxBorderLine aBrd( 0, DEF_LINE_WIDTH_0, 0, 0 ); // einfache Linien int bWeiter = sal_True, nBorderTyp = 0; ->>>>>>> ooo/DEV300_m101 do { switch( nToken ) @@ -1765,13 +1660,8 @@ SETBORDERLINE: if( nSkip ) { -<<<<<<< HEAD SkipToken( nSkip ); // Ignore back again - bWeiter = FALSE; -======= - SkipToken( nSkip ); // Ignore wieder zurueck bWeiter = sal_False; ->>>>>>> ooo/DEV300_m101 } } break; @@ -1796,17 +1686,10 @@ inline sal_uInt32 CalcShading( sal_uInt32 nColor, sal_uInt32 nFillColor, sal_uIn void SvxRTFParser::ReadBackgroundAttr( int nToken, SfxItemSet& rSet, int bTableDef ) { -<<<<<<< HEAD // then read the border attribute - int bWeiter = TRUE; - USHORT nColor = USHRT_MAX, nFillColor = USHRT_MAX; - BYTE nFillValue = 0; -======= - // dann lese doch mal das BoderAttribut ein int bWeiter = sal_True; sal_uInt16 nColor = USHRT_MAX, nFillColor = USHRT_MAX; sal_uInt8 nFillValue = 0; ->>>>>>> ooo/DEV300_m101 sal_uInt16 nWh = ( nToken & ~0xff ) == RTF_CHRFMT ? PLAINID->nBgColor @@ -1929,11 +1812,7 @@ void SvxRTFParser::ReadBackgroundAttr( int nToken, SfxItemSet& rSet, // pard / plain abarbeiten void SvxRTFParser::RTFPardPlain( int bPard, SfxItemSet** ppSet ) { -<<<<<<< HEAD - if( !bNewGroup && aAttrStack.Top() ) // not at the beginning of a new group -======= if( !bNewGroup && !aAttrStack.empty() ) // not at the beginning of a new group ->>>>>>> ooo/DEV300_m101 { SvxRTFItemStackType* pAkt = aAttrStack.back(); @@ -1945,13 +1824,8 @@ void SvxRTFParser::RTFPardPlain( int bPard, SfxItemSet** ppSet ) { if( pAkt->aAttrSet.Count() || pAkt->pChildList || pAkt->nStyleNo ) { -<<<<<<< HEAD // open a new group - SvxRTFItemStackType* pNew = new SvxRTFItemStackType( *pAkt, *pInsPos, TRUE ); -======= - // eine neue Gruppe aufmachen SvxRTFItemStackType* pNew = new SvxRTFItemStackType( *pAkt, *pInsPos, sal_True ); ->>>>>>> ooo/DEV300_m101 pNew->SetRTFDefaults( GetRTFDefaults() ); // Set all until here valid attributes @@ -2079,13 +1953,8 @@ void SvxRTFParser::SetDefault( int nToken, int nValue ) case RTF_DEFTAB: if( PARDID->nTabStop ) { -<<<<<<< HEAD // RTF defines 720 twips as default - bIsSetDfltTab = TRUE; -======= - // RTF definiert 720 twips als default bIsSetDfltTab = sal_True; ->>>>>>> ooo/DEV300_m101 if( -1 == nValue || !nValue ) nValue = 720; @@ -2096,44 +1965,11 @@ void SvxRTFParser::SetDefault( int nToken, int nValue ) CalcValue(); nValue = nTokenValue; } -<<<<<<< HEAD // Calculate the ratio of default TabWidth / Tabs and // calculate the corresponding new number. // ?? how did one come up with 13 ?? - USHORT nAnzTabs = (SVX_TAB_DEFDIST * 13 ) / USHORT(nValue); -======= -#if 1 - /* - cmc: - This stuff looks a little hairy indeed, this should be totally - unnecessary where default tabstops are understood. Just make one - tabstop and stick the value in there, the first one is all that - matters. - - e.g. - - SvxTabStopItem aNewTab(1, sal_uInt16(nValue), SVX_TAB_ADJUST_DEFAULT, - PARDID->nTabStop); - ((SvxTabStop&)aNewTab[0]).GetAdjustment() = SVX_TAB_ADJUST_DEFAULT; - - - It must exist as a foul hack to support somebody that does not - have a true concept of default tabstops by making a tabsetting - result from the default tabstop, creating a lot of them all at - the default locations to give the effect of the first real - default tabstop being in use just in case the receiving - application doesn't do that for itself. - */ -#endif - - // Verhaeltnis der def. TabWidth / Tabs errechnen und - // enstsprechend die neue Anzahl errechnen. -/*-----------------14.12.94 19:32------------------- - ?? wie kommt man auf die 13 ?? ---------------------------------------------------*/ sal_uInt16 nAnzTabs = (SVX_TAB_DEFDIST * 13 ) / sal_uInt16(nValue); ->>>>>>> ooo/DEV300_m101 /* cmc, make sure we have at least one, or all hell breaks loose in everybodies exporters, #i8247# @@ -2141,13 +1977,8 @@ void SvxRTFParser::SetDefault( int nToken, int nValue ) if (nAnzTabs < 1) nAnzTabs = 1; -<<<<<<< HEAD // we want Defaulttabs - SvxTabStopItem aNewTab( nAnzTabs, USHORT(nValue), -======= - // wir wollen Defaulttabs SvxTabStopItem aNewTab( nAnzTabs, sal_uInt16(nValue), ->>>>>>> ooo/DEV300_m101 SVX_TAB_ADJUST_DEFAULT, PARDID->nTabStop ); while( nAnzTabs ) ((SvxTabStop&)aNewTab[ --nAnzTabs ]).GetAdjustment() = SVX_TAB_ADJUST_DEFAULT; |