sw/inc/htmltbl.hxx | 56 ++++++++++++------------- sw/source/core/doc/htmltbl.cxx | 28 ++++++------ sw/source/filter/html/htmltab.cxx | 76 +++++++++++++++++------------------ sw/source/filter/html/htmltabw.cxx | 18 ++++---- sw/source/filter/inc/wrtswtbl.hxx | 47 ++++++++++----------- sw/source/filter/writer/wrtswtbl.cxx | 18 ++++---- sw/source/filter/xml/xmltble.cxx | 2 7 files changed, 121 insertions(+), 124 deletions(-)
New commits: commit 49082c20dc5d65fbf0a64c9f6d7aba626523c9a1 Author: Takeshi Abe <t...@fixedpoint.jp> Date: Tue Nov 13 06:13:47 2012 +0900 sal_Bool to bool Change-Id: I392709e11df3b2babfaa2cf4f90caf7ef29b10aa diff --git a/sw/inc/htmltbl.hxx b/sw/inc/htmltbl.hxx index 2f027e9..6c93b71 100644 --- a/sw/inc/htmltbl.hxx +++ b/sw/inc/htmltbl.hxx @@ -100,15 +100,15 @@ class SwHTMLTableLayoutCell sal_uInt16 nColSpan; ///< COLSPAN of cell. sal_uInt16 nWidthOption; ///< Given width of cell in Twip or %. - sal_Bool bPrcWidthOption : 1; ///< nWidth is %-value. - sal_Bool bNoWrapOption : 1; ///< NOWRAP-option. + bool bPrcWidthOption : 1; ///< nWidth is %-value. + bool bNoWrapOption : 1; ///< NOWRAP-option. public: SwHTMLTableLayoutCell( SwHTMLTableLayoutCnts *pCnts, sal_uInt16 nRSpan, sal_uInt16 nCSpan, - sal_uInt16 nWidthOpt, sal_Bool bPrcWdthOpt, - sal_Bool nNWrapOpt ); + sal_uInt16 nWidthOpt, bool bPrcWdthOpt, + bool nNWrapOpt ); ~SwHTMLTableLayoutCell(); @@ -124,9 +124,9 @@ public: sal_uInt16 GetColSpan() const { return nColSpan; } sal_uInt16 GetWidthOption() const { return nWidthOption; } - sal_Bool IsPrcWidthOption() const { return bPrcWidthOption; } + bool IsPrcWidthOption() const { return bPrcWidthOption; } - sal_Bool HasNoWrapOption() const { return bNoWrapOption; } + bool HasNoWrapOption() const { return bNoWrapOption; } }; class SwHTMLTableLayoutColumn @@ -144,27 +144,27 @@ class SwHTMLTableLayoutColumn sal_uInt16 nWidthOption; ///< Options of <COL> or <TD>/<TH>. - sal_Bool bRelWidthOption : 1; - sal_Bool bLeftBorder : 1; + bool bRelWidthOption : 1; + bool bLeftBorder : 1; public: - SwHTMLTableLayoutColumn( sal_uInt16 nColWidthOpt, sal_Bool bRelColWidthOpt, - sal_Bool bLBorder ); + SwHTMLTableLayoutColumn( sal_uInt16 nColWidthOpt, bool bRelColWidthOpt, + bool bLBorder ); ~SwHTMLTableLayoutColumn() {} - inline void MergeCellWidthOption( sal_uInt16 nWidth, sal_Bool bPrc ); - inline void SetWidthOption( sal_uInt16 nWidth, sal_Bool bRelWidth, sal_Bool bTest ); + inline void MergeCellWidthOption( sal_uInt16 nWidth, bool bPrc ); + inline void SetWidthOption( sal_uInt16 nWidth, bool bRelWidth, bool bTest ); sal_uInt16 GetWidthOption() const { return nWidthOption; } - sal_Bool IsRelWidthOption() const { return bRelWidthOption; } + bool IsRelWidthOption() const { return bRelWidthOption; } inline void MergeMinMaxNoAlign( sal_uLong nMin, sal_uLong nMax, sal_uLong nAbsMin ); sal_uLong GetMinNoAlign() const { return nMinNoAlign; } sal_uLong GetMaxNoAlign() const { return nMaxNoAlign; } sal_uLong GetAbsMinNoAlign() const { return nAbsMinNoAlign; } - inline void ClearPass1Info( sal_Bool bWidthOpt ); + inline void ClearPass1Info( bool bWidthOpt ); inline void SetMinMax( sal_uLong nMin, sal_uLong nMax ); void SetMax( sal_uLong nVal ) { nMax = nVal; } @@ -179,7 +179,7 @@ public: void SetRelColWidth( sal_uInt16 nWidth ) { nRelColWidth = nWidth; } sal_uInt16 GetRelColWidth() const { return nRelColWidth; } - sal_Bool HasLeftBorder() const { return bLeftBorder; } + bool HasLeftBorder() const { return bLeftBorder; } }; class SwHTMLTableLayout @@ -230,10 +230,10 @@ class SwHTMLTableLayout SvxAdjust eTableAdjust; ///< Alignment of table. - sal_Bool bColsOption : 1; ///< Table has a COLS-option. - sal_Bool bColTags : 1; ///< Tabelle has COL/COLGRP-tags. - sal_Bool bPrcWidthOption : 1; ///< Width is given in percent. - sal_Bool bUseRelWidth : 1; ///< SwTable gets relative width. + bool bColsOption : 1; ///< Table has a COLS-option. + bool bColTags : 1; ///< Tabelle has COL/COLGRP-tags. + bool bPrcWidthOption : 1; ///< Width is given in percent. + bool bUseRelWidth : 1; ///< SwTable gets relative width. sal_Bool bMustResize : 1; ///< Table width must be defined. sal_Bool bExportable : 1; ///< Layout may be used for export. @@ -263,8 +263,8 @@ class SwHTMLTableLayout public: SwHTMLTableLayout( const SwTable *pSwTbl, - sal_uInt16 nRows, sal_uInt16 nCols, sal_Bool bColsOpt, sal_Bool ColTgs, - sal_uInt16 nWidth, sal_Bool bPrcWidth, sal_uInt16 nBorderOpt, + sal_uInt16 nRows, sal_uInt16 nCols, bool bColsOpt, bool ColTgs, + sal_uInt16 nWidth, bool bPrcWidth, sal_uInt16 nBorderOpt, sal_uInt16 nCellPad, sal_uInt16 nCellSp, SvxAdjust eAdjust, sal_uInt16 nLMargin, sal_uInt16 nRMargin, sal_uInt16 nBWidth, sal_uInt16 nLeftBWidth, sal_uInt16 nRightBWidth, @@ -309,8 +309,8 @@ public: inline long GetBrowseWidthMin() const; - sal_Bool HasColsOption() const { return bColsOption; } - sal_Bool HasColTags() const { return bColTags; } + bool HasColsOption() const { return bColsOption; } + bool HasColTags() const { return bColTags; } sal_Bool IsTopTable() const { return pSwTable != 0; } @@ -347,7 +347,7 @@ public: /// For Export. sal_uInt16 GetWidthOption() const { return nWidthOption; } - sal_Bool HasPrcWidthOption() const { return bPrcWidthOption; } + bool HasPrcWidthOption() const { return bPrcWidthOption; } sal_uInt16 GetCellPadding() const { return nCellPadding; } sal_uInt16 GetCellSpacing() const { return nCellSpacing; } @@ -384,19 +384,19 @@ inline void SwHTMLTableLayoutColumn::MergeMinMaxNoAlign( sal_uLong nCMin, nAbsMinNoAlign = nAbsMin; } -inline void SwHTMLTableLayoutColumn::ClearPass1Info( sal_Bool bWidthOpt ) +inline void SwHTMLTableLayoutColumn::ClearPass1Info( bool bWidthOpt ) { nMinNoAlign = nMaxNoAlign = nAbsMinNoAlign = MINLAY; nMin = nMax = 0; if( bWidthOpt ) { nWidthOption = 0; - bRelWidthOption = sal_False; + bRelWidthOption = false; } } inline void SwHTMLTableLayoutColumn::MergeCellWidthOption( - sal_uInt16 nWidth, sal_Bool bRel ) + sal_uInt16 nWidth, bool bRel ) { if( !nWidthOption || (bRel==bRelWidthOption && nWidthOption < nWidth) ) @@ -430,7 +430,7 @@ inline SwHTMLTableLayoutColumn *SwHTMLTableLayout::GetColumn( sal_uInt16 nCol ) } inline void SwHTMLTableLayoutColumn::SetWidthOption( - sal_uInt16 nWidth, sal_Bool bRelWidth, sal_Bool bTest ) + sal_uInt16 nWidth, bool bRelWidth, bool bTest ) { if( bTest && bRelWidthOption==bRelWidth ) { diff --git a/sw/source/core/doc/htmltbl.cxx b/sw/source/core/doc/htmltbl.cxx index 409ae1c..bed2217 100644 --- a/sw/source/core/doc/htmltbl.cxx +++ b/sw/source/core/doc/htmltbl.cxx @@ -108,8 +108,8 @@ const SwStartNode *SwHTMLTableLayoutCnts::GetStartNode() const SwHTMLTableLayoutCell::SwHTMLTableLayoutCell( SwHTMLTableLayoutCnts *pCnts, sal_uInt16 nRSpan, sal_uInt16 nCSpan, - sal_uInt16 nWidth, sal_Bool bPrcWidth, - sal_Bool bNWrapOpt ) : + sal_uInt16 nWidth, bool bPrcWidth, + bool bNWrapOpt ) : pContents( pCnts ), nRowSpan( nRSpan ), nColSpan( nCSpan ), nWidthOption( nWidth ), bPrcWidthOption( bPrcWidth ), @@ -126,8 +126,8 @@ SwHTMLTableLayoutCell::~SwHTMLTableLayoutCell() SwHTMLTableLayoutColumn::SwHTMLTableLayoutColumn( sal_uInt16 nWidth, - sal_Bool bRelWidth, - sal_Bool bLBorder ) : + bool bRelWidth, + bool bLBorder ) : nMinNoAlign(MINLAY), nMaxNoAlign(MINLAY), nAbsMinNoAlign(MINLAY), nMin(0), nMax(0), nAbsColWidth(0), nRelColWidth(0), @@ -183,8 +183,8 @@ typedef SwHTMLTableLayoutCell *SwHTMLTableLayoutCellPtr; SwHTMLTableLayout::SwHTMLTableLayout( const SwTable * pSwTbl, - sal_uInt16 nRws, sal_uInt16 nCls, sal_Bool bColsOpt, sal_Bool bColTgs, - sal_uInt16 nWdth, sal_Bool bPrcWdth, sal_uInt16 nBorderOpt, + sal_uInt16 nRws, sal_uInt16 nCls, bool bColsOpt, bool bColTgs, + sal_uInt16 nWdth, bool bPrcWdth, sal_uInt16 nBorderOpt, sal_uInt16 nCellPad, sal_uInt16 nCellSp, SvxAdjust eAdjust, sal_uInt16 nLMargin, sal_uInt16 nRMargin, sal_uInt16 nBWidth, sal_uInt16 nLeftBWidth, @@ -207,7 +207,7 @@ SwHTMLTableLayout::SwHTMLTableLayout( nDelayedResizeAbsAvail( 0 ), nLastResizeAbsAvail( 0 ), nPass1Done( 0 ), nWidthSet( 0 ), eTableAdjust( eAdjust ), bColsOption( bColsOpt ), bColTags( bColTgs ), - bPrcWidthOption( bPrcWdth ), bUseRelWidth( sal_False ), + bPrcWidthOption( bPrcWdth ), bUseRelWidth( false ), bMustResize( sal_True ), bExportable( sal_True ), bBordersChanged( sal_False ), bMustNotResize( sal_False ), bMustNotRecalc( sal_False ) { @@ -469,7 +469,7 @@ void SwHTMLTableLayout::AutoLayoutPass1() ClearPass1Info(); - sal_Bool bFixRelWidths = sal_False; + bool bFixRelWidths = false; sal_uInt16 i; SwHTMLTableLayoutConstraints *pConstraints = 0; @@ -779,7 +779,7 @@ void SwHTMLTableLayout::AutoLayoutPass1() nMin += pColumn->GetMin(); nMax += pColumn->GetMax(); - bFixRelWidths |= pColumn->IsRelWidthOption(); + if (pColumn->IsRelWidthOption()) bFixRelWidths = true; } // Now process the constraints @@ -960,7 +960,7 @@ void SwHTMLTableLayout::AutoLayoutPass1() if( nRel+nColWidth > 100 ) { nColWidth = 100 - nRel; - pColumn->SetWidthOption( nColWidth, sal_True, sal_False ); + pColumn->SetWidthOption( nColWidth, true, false ); } nRelMax += pColumn->GetMax(); nRel = nRel + nColWidth; @@ -994,7 +994,7 @@ void SwHTMLTableLayout::AutoLayoutPass1() // the next column gets the rest sal_uInt16 nColWidth = (sal_uInt16)((pColumn->GetMax() * nRelLeft) / nFixMax); - pColumn->SetWidthOption( nColWidth, sal_True, sal_False ); + pColumn->SetWidthOption( nColWidth, true, false ); } } } @@ -1142,7 +1142,7 @@ void SwHTMLTableLayout::AutoLayoutPass2( sal_uInt16 nAbsAvail, sal_uInt16 nRelAv // Step 2: Calculate the absolute table width. sal_uInt16 nAbsTabWidth = 0; - bUseRelWidth = sal_False; + bUseRelWidth = false; if( nWidthOption ) { if( bPrcWidthOption ) @@ -1170,7 +1170,7 @@ void SwHTMLTableLayout::AutoLayoutPass2( sal_uInt16 nAbsAvail, sal_uInt16 nRelAv ( /*MayBeInFlyFrame() ||*/ (sal_uLong)nAbsTabWidth > nMin ) ) { nRelAvail = USHRT_MAX; - bUseRelWidth = sal_True; + bUseRelWidth = true; } } else @@ -1645,7 +1645,7 @@ void SwHTMLTableLayout::SetWidths( sal_Bool bCallPass2, sal_uInt16 nAbsAvail, ((SwTable *)pSwTable)->LockModify(); SwFmtFrmSize aFrmSize( pFrmFmt->GetFrmSize() ); aFrmSize.SetWidth( nRelTabWidth ); - sal_Bool bRel = bUseRelWidth && + bool bRel = bUseRelWidth && text::HoriOrientation::FULL!=pFrmFmt->GetHoriOrient().GetHoriOrient(); aFrmSize.SetWidthPercent( (sal_uInt8)(bRel ? nWidthOption : 0) ); pFrmFmt->SetFmtAttr( aFrmSize ); diff --git a/sw/source/filter/html/htmltab.cxx b/sw/source/filter/html/htmltab.cxx index ae4e4fe..fde8dbe 100644 --- a/sw/source/filter/html/htmltab.cxx +++ b/sw/source/filter/html/htmltab.cxx @@ -298,7 +298,7 @@ class HTMLTableRow public: - sal_Bool bBottomBorder; // Is there a line after the row? + bool bBottomBorder; // Is there a line after the row? HTMLTableRow( sal_uInt16 nCells=0 ); // cells of the row are empty @@ -354,7 +354,7 @@ class HTMLTableColumn public: - sal_Bool bLeftBorder; // is there a line before the column + bool bLeftBorder; // is there a line before the column HTMLTableColumn(); @@ -435,15 +435,15 @@ class HTMLTable SvxBorderLine aBorderLine; // die Linie fuer die Umrandung SvxBorderLine aInhLeftBorderLine; // die Linie fuer die Umrandung SvxBorderLine aInhRightBorderLine; // die Linie fuer die Umrandung - sal_Bool bTopBorder; // besitzt die Tabelle oben eine Linie - sal_Bool bRightBorder; // besitzt die Tabelle rechts eine Linie - sal_Bool bTopAlwd; // duerfen die Raender gesetzt werden? - sal_Bool bRightAlwd; - sal_Bool bFillerTopBorder; // bekommt eine linke/rechter Filler- - sal_Bool bFillerBottomBorder; // Zelle eine obere/untere Umrandung? - sal_Bool bInhLeftBorder; - sal_Bool bInhRightBorder; - sal_Bool bBordersSet; // die Umrandung wurde bereits gesetzt + bool bTopBorder; // besitzt die Tabelle oben eine Linie + bool bRightBorder; // besitzt die Tabelle rechts eine Linie + bool bTopAlwd; // duerfen die Raender gesetzt werden? + bool bRightAlwd; + bool bFillerTopBorder; // bekommt eine linke/rechter Filler- + bool bFillerBottomBorder; // Zelle eine obere/untere Umrandung? + bool bInhLeftBorder; + bool bInhRightBorder; + bool bBordersSet; // die Umrandung wurde bereits gesetzt sal_Bool bForceFrame; sal_Bool bTableAdjustOfTag; // stammt nTableAdjust aus <TABLE>? sal_uInt32 nHeadlineRepeat; // repeating rows @@ -452,7 +452,7 @@ class HTMLTable sal_Bool bMakeTopSubTable; sal_Bool bHasToFly; sal_Bool bFixedCols; - sal_Bool bColSpec; // Gab es COL(GROUP)-Elemente? + bool bColSpec; // Gab es COL(GROUP)-Elemente? sal_Bool bPrcWidth; // Breite ist eine %-Angabe SwHTMLParser *pParser; // der aktuelle Parser @@ -536,7 +536,7 @@ class HTMLTable void SetBorders(); // wurde die Umrandung der Tabelle schon gesetzt - sal_Bool BordersSet() const { return bBordersSet; } + bool BordersSet() const { return bBordersSet; } const SvxBrushItem *GetBGBrush() const { return pBGBrush; } const SvxBrushItem *GetInhBGBrush() const { return pInhBGBrush; } @@ -641,7 +641,7 @@ public: SwHTMLTableLayout *CreateLayoutInfo(); - sal_Bool HasColTags() const { return bColSpec; } + bool HasColTags() const { return bColSpec; } sal_uInt16 IncGrfsThatResize() { return pSwTable ? ((SwTable *)pSwTable)->IncGrfsThatResize() : 0; } @@ -824,7 +824,7 @@ HTMLTableRow::HTMLTableRow( sal_uInt16 nCells ): eAdjust(SVX_ADJUST_END), eVertOri(text::VertOrientation::TOP), pBGBrush(0), - bBottomBorder(sal_False) + bBottomBorder(false) { for( sal_uInt16 i=0; i<nCells; i++ ) { @@ -919,7 +919,7 @@ HTMLTableColumn::HTMLTableColumn(): bIsEndOfGroup(sal_False), nWidth(0), bRelWidth(sal_False), eAdjust(SVX_ADJUST_END), eVertOri(text::VertOrientation::TOP), - bLeftBorder(sal_False) + bLeftBorder(false) { for( sal_uInt16 i=0; i<6; i++ ) aFrmFmts[i] = 0; @@ -989,11 +989,11 @@ void HTMLTable::InitCtor( const HTMLTableOptions *pOptions ) pPrevStNd = 0; pSwTable = 0; - bTopBorder = sal_False; bRightBorder = sal_False; - bTopAlwd = sal_True; bRightAlwd = sal_True; - bFillerTopBorder = sal_False; bFillerBottomBorder = sal_False; - bInhLeftBorder = sal_False; bInhRightBorder = sal_False; - bBordersSet = sal_False; + bTopBorder = false; bRightBorder = false; + bTopAlwd = true; bRightAlwd = true; + bFillerTopBorder = false; bFillerBottomBorder = false; + bInhLeftBorder = false; bInhRightBorder = false; + bBordersSet = false; bForceFrame = sal_False; nHeadlineRepeat = 0; @@ -1082,7 +1082,7 @@ void HTMLTable::InitCtor( const HTMLTableOptions *pOptions ) nHSpace = (sal_uInt16)nPWidth; nVSpace = (sal_uInt16)nPHeight; - bColSpec = sal_False; + bColSpec = false; pBGBrush = pParser->CreateBrushItem( pOptions->bBGColor ? &(pOptions->aBGColor) : 0, @@ -1934,14 +1934,14 @@ void HTMLTable::InheritBorders( const HTMLTable *pParent, // if( 0==nRow && pParent->bTopBorder && bFirstPara ) { - bTopBorder = sal_True; - bFillerTopBorder = sal_True; // auch Filler bekommt eine Umrandung + bTopBorder = true; + bFillerTopBorder = true; // auch Filler bekommt eine Umrandung aTopBorderLine = pParent->aTopBorderLine; } if( (*pParent->pRows)[nRow+nRowSpan-1].bBottomBorder && bLastPara ) { - (*pRows)[nRows-1].bBottomBorder = sal_True; - bFillerBottomBorder = sal_True; // auch Filler bekommt eine Umrandung + (*pRows)[nRows-1].bBottomBorder = true; + bFillerBottomBorder = true; // auch Filler bekommt eine Umrandung aBottomBorderLine = nRow+nRowSpan==pParent->nRows ? pParent->aBottomBorderLine : pParent->aBorderLine; @@ -1983,7 +1983,7 @@ void HTMLTable::InheritVertBorders( const HTMLTable *pParent, if( nCol+nColSpan==pParent->nCols && pParent->bRightBorder ) { - bInhRightBorder = sal_True; // erstmal nur merken + bInhRightBorder = true; // erstmal nur merken aInhRightBorderLine = pParent->aRightBorderLine; nInhRightBorderWidth = GetBorderWidth( aInhRightBorderLine, sal_True ) + MIN_BORDER_DIST; @@ -1991,7 +1991,7 @@ void HTMLTable::InheritVertBorders( const HTMLTable *pParent, if( ((*pParent->pColumns)[nCol]).bLeftBorder ) { - bInhLeftBorder = sal_True; // erstmal nur merken + bInhLeftBorder = true; // erstmal nur merken aInhLeftBorderLine = 0==nCol ? pParent->aLeftBorderLine : pParent->aBorderLine; nInhLeftBorderWidth = @@ -2017,25 +2017,25 @@ void HTMLTable::SetBorders() if( HTML_TR_ALL==eRules || HTML_TR_COLS==eRules || ((HTML_TR_ROWS==eRules || HTML_TR_GROUPS==eRules) && ((*pColumns)[i-1]).IsEndOfGroup()) ) - ((*pColumns)[i]).bLeftBorder = sal_True; + ((*pColumns)[i]).bLeftBorder = true; for( i=0; i<nRows-1; i++ ) if( HTML_TR_ALL==eRules || HTML_TR_ROWS==eRules || ((HTML_TR_COLS==eRules || HTML_TR_GROUPS==eRules) && (*pRows)[i].IsEndOfGroup()) ) - (*pRows)[i].bBottomBorder = sal_True; + (*pRows)[i].bBottomBorder = true; if( bTopAlwd && (HTML_TF_ABOVE==eFrame || HTML_TF_HSIDES==eFrame || HTML_TF_BOX==eFrame) ) - bTopBorder = sal_True; + bTopBorder = true; if( HTML_TF_BELOW==eFrame || HTML_TF_HSIDES==eFrame || HTML_TF_BOX==eFrame ) - (*pRows)[nRows-1].bBottomBorder = sal_True; + (*pRows)[nRows-1].bBottomBorder = true; if( (HTML_TF_RHS==eFrame || HTML_TF_VSIDES==eFrame || HTML_TF_BOX==eFrame) ) - bRightBorder = sal_True; + bRightBorder = true; if( HTML_TF_LHS==eFrame || HTML_TF_VSIDES==eFrame || HTML_TF_BOX==eFrame ) - ((*pColumns)[0]).bLeftBorder = sal_True; + ((*pColumns)[0]).bLeftBorder = true; for( i=0; i<nRows; i++ ) { @@ -2066,7 +2066,7 @@ void HTMLTable::SetBorders() } } - bBordersSet = sal_True; + bBordersSet = true; } sal_uInt16 HTMLTable::GetBorderWidth( const SvxBorderLine& rBLine, @@ -2359,7 +2359,7 @@ void HTMLTable::InsertCol( sal_uInt16 nSpan, sal_uInt16 nColWidth, sal_Bool bRel pCol->SetVertOri( eVertOrient ); } - bColSpec = sal_True; + bColSpec = true; nCurCol = nColsReq; } @@ -2504,7 +2504,7 @@ void HTMLTable::MakeTable( SwTableBox *pBox, sal_uInt16 nAbsAvail, // linke Umrandung von auesserer Tabelle uebernehmen if( bInhRightBorder ) { - bRightBorder = sal_True; + bRightBorder = true; aRightBorderLine = aInhRightBorderLine; } } @@ -2520,7 +2520,7 @@ void HTMLTable::MakeTable( SwTableBox *pBox, sal_uInt16 nAbsAvail, bInhLeftBorder ) { // ggf. rechte Umrandung von auesserer Tabelle uebernehmen - ((*pColumns)[0]).bLeftBorder = sal_True; + ((*pColumns)[0]).bLeftBorder = true; aLeftBorderLine = aInhLeftBorderLine; } } diff --git a/sw/source/filter/html/htmltabw.cxx b/sw/source/filter/html/htmltabw.cxx index 3b96dfc..74cdaa6 100644 --- a/sw/source/filter/html/htmltabw.cxx +++ b/sw/source/filter/html/htmltabw.cxx @@ -285,7 +285,7 @@ void SwHTMLWrtTable::OutTableCell( SwHTMLWriter& rWrt, SwWriteTableCol *pCol = aCols[nCol]; #endif - sal_Bool bOutWidth = sal_True; + bool bOutWidth = true; const SwStartNode* pSttNd = pBox->GetSttNd(); sal_Bool bHead = sal_False; @@ -353,7 +353,7 @@ void SwHTMLWrtTable::OutTableCell( SwHTMLWriter& rWrt, { nWidth = pCell->GetWidthOpt(); if( !nWidth ) - bOutWidth = sal_False; + bOutWidth = false; } } else @@ -396,7 +396,7 @@ void SwHTMLWrtTable::OutTableCell( SwHTMLWriter& rWrt, sOut.append(static_cast<sal_Int32>(aPixelSz.Width())); } if( !bLayoutExport && nColSpan==1 ) - pCol->SetOutWidth( sal_False ); + pCol->SetOutWidth( false ); } if( nHeight ) @@ -788,7 +788,7 @@ void SwHTMLWrtTable::Write( SwHTMLWriter& rWrt, sal_Int16 eAlign, sOutStr.append('<').append(OOO_STRING_SVTOOLS_HTML_col); sal_uInt32 nWidth; - sal_Bool bRel; + bool bRel; if( bLayoutExport ) { bRel = pColumn->HasRelWidthOpt(); @@ -967,14 +967,14 @@ Writer& OutHTML_SwTblNode( Writer& rWrt, SwTableNode & rNode, // text::HoriOrientation::NONE und text::HoriOrientation::FULL Tabellen benoetigen relative Breiten sal_uInt16 nNewDefListLvl = 0; - sal_Bool bRelWidths = sal_False; + bool bRelWidths = false; sal_Bool bCheckDefList = sal_False; switch( eTabHoriOri ) { case text::HoriOrientation::FULL: // Tabellen mit automatischer Ausrichtung werden zu Tabellen // mit 100%-Breite - bRelWidths = sal_True; + bRelWidths = true; nWidth = 100; eTabHoriOri = text::HoriOrientation::LEFT; break; @@ -991,7 +991,7 @@ Writer& OutHTML_SwTblNode( Writer& rWrt, SwTableNode & rNode, nWidth = pFmt->FindLayoutRect(sal_True).Width(); if( !nWidth ) { - bRelWidths = sal_True; + bRelWidths = true; nWidth = 100; } @@ -1000,7 +1000,7 @@ Writer& OutHTML_SwTblNode( Writer& rWrt, SwTableNode & rNode, { // Ohne rechten Rand bleibt die %-Breite erhalten nWidth = nPrcWidth; - bRelWidths = sal_True; + bRelWidths = true; } else { @@ -1023,7 +1023,7 @@ Writer& OutHTML_SwTblNode( Writer& rWrt, SwTableNode & rNode, // Breite direkt uebernommen werden. if( nPrcWidth ) { - bRelWidths = sal_True; + bRelWidths = true; nWidth = nPrcWidth; } break; diff --git a/sw/source/filter/inc/wrtswtbl.hxx b/sw/source/filter/inc/wrtswtbl.hxx index 5fed32e..2d4b75b 100644 --- a/sw/source/filter/inc/wrtswtbl.hxx +++ b/sw/source/filter/inc/wrtswtbl.hxx @@ -71,7 +71,7 @@ class SW_DLLPUBLIC SwWriteTableCell sal_uInt16 nColSpan; // ueberspannte Spalten - sal_Bool bPrcWidthOpt; + bool bPrcWidthOpt; public: @@ -79,7 +79,7 @@ public: sal_uInt16 nCSpan, long nHght, const SvxBrushItem *pBGround) : pBox( pB ), pBackground( pBGround ), nHeight( nHght ), nWidthOpt( 0 ), nRow( nR ), nCol( nC ), nRowSpan( nRSpan ), nColSpan( nCSpan ), - bPrcWidthOpt( sal_False ) + bPrcWidthOpt( false ) {} const SwTableBox *GetBox() const { return pBox; } @@ -95,13 +95,13 @@ public: const SvxBrushItem *GetBackground() const { return pBackground; } - void SetWidthOpt( sal_uInt16 nWidth, sal_Bool bPrc ) + void SetWidthOpt( sal_uInt16 nWidth, bool bPrc ) { nWidthOpt = nWidth; bPrcWidthOpt = bPrc; } sal_uInt32 GetWidthOpt() const { return nWidthOpt; } - sal_Bool HasPrcWidthOpt() const { return bPrcWidthOpt; } + bool HasPrcWidthOpt() const { return bPrcWidthOpt; } }; typedef boost::ptr_vector<SwWriteTableCell> SwWriteTableCells; @@ -131,8 +131,8 @@ public: sal_uInt16 nTopBorder; // Dicke der oberen/unteren Umrandugen sal_uInt16 nBottomBorder; - sal_Bool bTopBorder : 1; // Welche Umrandungen sind da? - sal_Bool bBottomBorder : 1; + bool bTopBorder : 1; // Welche Umrandungen sind da? + bool bBottomBorder : 1; SwWriteTableRow( long nPos, sal_Bool bUseLayoutHeights ); @@ -148,8 +148,8 @@ public: } const SvxBrushItem *GetBackground() const { return pBackground; } - sal_Bool HasTopBorder() const { return bTopBorder; } - sal_Bool HasBottomBorder() const { return bBottomBorder; } + bool HasTopBorder() const { return bTopBorder; } + bool HasBottomBorder() const { return bBottomBorder; } long GetPos() const { return nPos; } const SwWriteTableCells& GetCells() const { return aCells; } @@ -186,32 +186,32 @@ class SW_DLLPUBLIC SwWriteTableCol sal_uInt32 nWidthOpt; - sal_Bool bRelWidthOpt : 1; - sal_Bool bOutWidth : 1; // Spaltenbreite ausgeben? + bool bRelWidthOpt : 1; + bool bOutWidth : 1; // Spaltenbreite ausgeben? public: - sal_Bool bLeftBorder : 1; // Welche Umrandungen sind da? - sal_Bool bRightBorder : 1; + bool bLeftBorder : 1; // Welche Umrandungen sind da? + bool bRightBorder : 1; SwWriteTableCol( sal_uInt32 nPosition ); sal_uInt32 GetPos() const { return nPos; } - sal_Bool HasLeftBorder() const { return bLeftBorder; } + bool HasLeftBorder() const { return bLeftBorder; } - sal_Bool HasRightBorder() const { return bRightBorder; } + bool HasRightBorder() const { return bRightBorder; } - void SetOutWidth( sal_Bool bSet ) { bOutWidth = bSet; } + void SetOutWidth( bool bSet ) { bOutWidth = bSet; } inline int operator==( const SwWriteTableCol& rCol ) const; inline int operator<( const SwWriteTableCol& rCol ) const; - void SetWidthOpt( sal_uInt32 nWidth, sal_Bool bRel ) + void SetWidthOpt( sal_uInt32 nWidth, bool bRel ) { nWidthOpt = nWidth; bRelWidthOpt = bRel; } sal_uInt32 GetWidthOpt() const { return nWidthOpt; } - sal_Bool HasRelWidthOpt() const { return bRelWidthOpt; } + bool HasRelWidthOpt() const { return bRelWidthOpt; } }; inline int SwWriteTableCol::operator==( const SwWriteTableCol& rCol ) const @@ -258,14 +258,14 @@ protected: sal_uInt32 nTabWidth; // Absolute/Relative Breite der Tabelle - sal_Bool bRelWidths : 1; // Breiten relativ ausgeben? + bool bRelWidths : 1; // Breiten relativ ausgeben? sal_Bool bUseLayoutHeights : 1; // Layout zur Hoehenbestimmung nehmen? #ifdef DBG_UTIL sal_Bool m_bGetLineHeightCalled : 1; #endif - sal_Bool bColsOption : 1; - sal_Bool bColTags : 1; + bool bColsOption : 1; + bool bColTags : 1; sal_Bool bLayoutExport : 1; sal_Bool bCollectBorderWidth : 1; @@ -295,7 +295,7 @@ protected: sal_uInt32 GetBaseWidth() const { return nBaseWidth; } - sal_Bool HasRelWidths() const { return bRelWidths; } + bool HasRelWidths() const { return bRelWidths; } public: static sal_uInt32 GetBoxWidth( const SwTableBox *pBox ); @@ -319,7 +319,7 @@ protected: public: SwWriteTable( const SwTableLines& rLines, long nWidth, sal_uInt32 nBWidth, - sal_Bool bRel, sal_uInt16 nMaxDepth = USHRT_MAX, + bool bRel, sal_uInt16 nMaxDepth = USHRT_MAX, sal_uInt16 nLeftSub=0, sal_uInt16 nRightSub=0, sal_uInt32 nNumOfRowsToRepeat=0 ); SwWriteTable( const SwHTMLTableLayout *pLayoutInfo ); virtual ~SwWriteTable(); diff --git a/sw/source/filter/writer/wrtswtbl.cxx b/sw/source/filter/writer/wrtswtbl.cxx index ef8697c..f9865f8 100644 --- a/sw/source/filter/writer/wrtswtbl.cxx +++ b/sw/source/filter/writer/wrtswtbl.cxx @@ -695,7 +695,7 @@ void SwWriteTable::FillTableRowsCols( long nStartRPos, sal_uInt16 nStartRow, SwWriteTableCol *pCol = aCols[nOldCol]; OSL_ENSURE(pCol, "No TableCol found, panic!"); if (pCol) - pCol->bLeftBorder = sal_False; + pCol->bLeftBorder = false; } if (!(nBorderMask & 8)) @@ -703,16 +703,16 @@ void SwWriteTable::FillTableRowsCols( long nStartRPos, sal_uInt16 nStartRow, SwWriteTableCol *pCol = aCols[nCol]; OSL_ENSURE(pCol, "No TableCol found, panic!"); if (pCol) - pCol->bRightBorder = sal_False; + pCol->bRightBorder = false; } if (!(nBorderMask & 1)) - pRow->bTopBorder = sal_False; + pRow->bTopBorder = false; else if (!pRow->nTopBorder || nTopBorder < pRow->nTopBorder) pRow->nTopBorder = nTopBorder; if (!(nBorderMask & 2)) - pEndRow->bBottomBorder = sal_False; + pEndRow->bBottomBorder = false; else if ( !pEndRow->nBottomBorder || nBottomBorder < pEndRow->nBottomBorder @@ -740,7 +740,7 @@ void SwWriteTable::FillTableRowsCols( long nStartRPos, sal_uInt16 nStartRow, } SwWriteTable::SwWriteTable(const SwTableLines& rLines, long nWidth, - sal_uInt32 nBWidth, sal_Bool bRel, sal_uInt16 nMaxDepth, sal_uInt16 nLSub, sal_uInt16 nRSub, sal_uInt32 nNumOfRowsToRepeat) + sal_uInt32 nBWidth, bool bRel, sal_uInt16 nMaxDepth, sal_uInt16 nLSub, sal_uInt16 nRSub, sal_uInt32 nNumOfRowsToRepeat) : nBorderColor((sal_uInt32)-1), nCellSpacing(0), nCellPadding(0), nBorder(0), nInnerBorder(0), nBaseWidth(nBWidth), nHeadEndRow(USHRT_MAX), nLeftSub(nLSub), nRightSub(nRSub), nTabWidth(nWidth), bRelWidths(bRel), @@ -862,18 +862,18 @@ SwWriteTable::SwWriteTable( const SwHTMLTableLayout *pLayoutInfo ) SwWriteTableCol *pCol = aCols[nCol]; if( !(nBorderMask & 4) ) - pCol->bLeftBorder = sal_False; + pCol->bLeftBorder = false; pCol = aCols[nCol+nColSpan-1]; if( !(nBorderMask & 8) ) - pCol->bRightBorder = sal_False; + pCol->bRightBorder = false; if( !(nBorderMask & 1) ) - pRow->bTopBorder = sal_False; + pRow->bTopBorder = false; SwWriteTableRow *pEndRow = aRows[nRow+nRowSpan-1]; if( !(nBorderMask & 2) ) - pEndRow->bBottomBorder = sal_False; + pEndRow->bBottomBorder = false; // Die Hoehe braucht nur einmal geschieben werden if( nHeight ) diff --git a/sw/source/filter/xml/xmltble.cxx b/sw/source/filter/xml/xmltble.cxx index dd50070..50eb078 100644 --- a/sw/source/filter/xml/xmltble.cxx +++ b/sw/source/filter/xml/xmltble.cxx @@ -625,7 +625,7 @@ void SwXMLExport::ExportTableLinesAutoStyles( const SwTableLines& rLines, nColAbsWidth += (nBaseWidth/2UL); nColAbsWidth /= nBaseWidth; } - pColumn->SetWidthOpt( nColAbsWidth, sal_False ); + pColumn->SetWidthOpt( nColAbsWidth, false ); } SwXMLTableColumnsSortByWidth_Impl::const_iterator it = rExpCols.find( pColumn ); commit 0cd4f312e3957a60ff5168f7fe77d736ee2ca4d4 Author: Takeshi Abe <t...@fixedpoint.jp> Date: Mon Nov 12 18:29:42 2012 +0900 Drop unused functions Change-Id: Iff3dc8149cbe6dbf3827fa6817676777a528e93b diff --git a/sw/source/filter/inc/wrtswtbl.hxx b/sw/source/filter/inc/wrtswtbl.hxx index 15f87bd..5fed32e 100644 --- a/sw/source/filter/inc/wrtswtbl.hxx +++ b/sw/source/filter/inc/wrtswtbl.hxx @@ -197,14 +197,11 @@ public: sal_uInt32 GetPos() const { return nPos; } - void SetLeftBorder( sal_Bool bBorder ) { bLeftBorder = bBorder; } sal_Bool HasLeftBorder() const { return bLeftBorder; } - void SetRightBorder( sal_Bool bBorder ) { bRightBorder = bBorder; } sal_Bool HasRightBorder() const { return bRightBorder; } void SetOutWidth( sal_Bool bSet ) { bOutWidth = bSet; } - sal_Bool GetOutWidth() const { return bOutWidth; } inline int operator==( const SwWriteTableCol& rCol ) const; inline int operator<( const SwWriteTableCol& rCol ) const; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits