summaryrefslogtreecommitdiff
path: root/sc/source/core/data/table5.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sc/source/core/data/table5.cxx')
-rw-r--r--sc/source/core/data/table5.cxx76
1 files changed, 38 insertions, 38 deletions
diff --git a/sc/source/core/data/table5.cxx b/sc/source/core/data/table5.cxx
index 7c13756aab38..0548e3ce0abd 100644
--- a/sc/source/core/data/table5.cxx
+++ b/sc/source/core/data/table5.cxx
@@ -106,7 +106,7 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea )
}
else
{
- USHORT nAreaCount = GetPrintRangeCount();
+ sal_uInt16 nAreaCount = GetPrintRangeCount();
if ( nAreaCount > 1 )
{
// bei mehreren Bereichen nichts anzeigen:
@@ -136,13 +136,13 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea )
bool bSkipColBreaks = false;
bool bSkipRowBreaks = false;
- if ( pStyleSet->GetItemState( ATTR_PAGE_SCALETOPAGES, FALSE, &pItem ) == SFX_ITEM_SET )
+ if ( pStyleSet->GetItemState( ATTR_PAGE_SCALETOPAGES, sal_False, &pItem ) == SFX_ITEM_SET )
{
DBG_ASSERT( pItem->ISA(SfxUInt16Item), "falsches Item" );
bSkipColBreaks = bSkipRowBreaks = ( ((const SfxUInt16Item*)pItem)->GetValue() > 0 );
}
- if ( !bSkipColBreaks && pStyleSet->GetItemState(ATTR_PAGE_SCALETO, FALSE, &pItem) == SFX_ITEM_SET )
+ if ( !bSkipColBreaks && pStyleSet->GetItemState(ATTR_PAGE_SCALETO, sal_False, &pItem) == SFX_ITEM_SET )
{
// #i54993# when fitting to width or height, ignore only manual breaks in that direction
const ScPageScaleToItem* pScaleToItem = static_cast<const ScPageScaleToItem*>(pItem);
@@ -170,24 +170,24 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea )
// Mittelteil: Breaks verteilen
- BOOL bRepeatCol = ( nRepeatStartX != SCCOL_REPEAT_NONE );
- BOOL bColFound = FALSE;
+ sal_Bool bRepeatCol = ( nRepeatStartX != SCCOL_REPEAT_NONE );
+ sal_Bool bColFound = sal_False;
long nSizeX = 0;
for (nX=nStartCol; nX<=nEndCol; nX++)
{
- BOOL bStartOfPage = FALSE;
+ sal_Bool bStartOfPage = sal_False;
long nThisX = ColHidden(nX) ? 0 : pColWidth[nX];
bool bManualBreak = HasColManualBreak(nX);
if ( (nSizeX+nThisX > nPageSizeX) || (bManualBreak && !bSkipColBreaks) )
{
SetColBreak(nX, true, false);
nSizeX = 0;
- bStartOfPage = TRUE;
+ bStartOfPage = sal_True;
}
else if (nX != nStartCol)
RemoveColBreak(nX, true, false);
else
- bStartOfPage = TRUE;
+ bStartOfPage = sal_True;
if ( bStartOfPage && bRepeatCol && nX>nRepeatStartX && !bColFound )
{
@@ -196,7 +196,7 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea )
nPageSizeX -= ColHidden(i) ? 0 : pColWidth[i];
while (nX<=nRepeatEndX)
RemoveColBreak(++nX, true, false);
- bColFound = TRUE;
+ bColFound = sal_True;
}
nSizeX += nThisX;
@@ -206,15 +206,15 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea )
RemoveRowPageBreaks(nStartRow+1, nEndRow);
// And set new page breaks.
- BOOL bRepeatRow = ( nRepeatStartY != SCROW_REPEAT_NONE );
- BOOL bRowFound = FALSE;
+ sal_Bool bRepeatRow = ( nRepeatStartY != SCROW_REPEAT_NONE );
+ sal_Bool bRowFound = sal_False;
long nSizeY = 0;
ScFlatBoolRowSegments::ForwardIterator aIterHidden(*mpHiddenRows);
ScFlatUInt16RowSegments::ForwardIterator aIterHeights(*mpRowHeights);
SCROW nNextManualBreak = GetNextManualBreak(nStartRow); // -1 => no more manual breaks
for (SCROW nY = nStartRow; nY <= nEndRow; ++nY)
{
- BOOL bStartOfPage = FALSE;
+ sal_Bool bStartOfPage = sal_False;
bool bThisRowHidden = false;
aIterHidden.getValue(nY, bThisRowHidden);
long nThisY = 0;
@@ -238,12 +238,12 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea )
{
SetRowBreak(nY, true, false);
nSizeY = 0;
- bStartOfPage = TRUE;
+ bStartOfPage = sal_True;
}
else if (nY != nStartRow)
; // page break already removed
else
- bStartOfPage = TRUE;
+ bStartOfPage = sal_True;
if ( bStartOfPage && bRepeatRow && nY>nRepeatStartY && !bRowFound )
{
@@ -256,7 +256,7 @@ void ScTable::UpdatePageBreaks( const ScRange* pUserArea )
nPageSizeY -= nHeights;
if (nY <= nRepeatEndY)
RemoveRowPageBreaks(nY, nRepeatEndY);
- bRowFound = TRUE;
+ bRowFound = sal_True;
}
if (bThisRowHidden)
@@ -318,10 +318,10 @@ void ScTable::RemoveManualBreaks()
InvalidatePageBreaks();
if (IsStreamValid())
- SetStreamValid(FALSE);
+ SetStreamValid(sal_False);
}
-BOOL ScTable::HasManualBreaks() const
+sal_Bool ScTable::HasManualBreaks() const
{
return !maRowManualBreaks.empty() || !maColManualBreaks.empty();
}
@@ -331,7 +331,7 @@ void ScTable::SetRowManualBreaks( const ::std::set<SCROW>& rBreaks )
maRowManualBreaks = rBreaks;
InvalidatePageBreaks();
if (IsStreamValid())
- SetStreamValid(FALSE);
+ SetStreamValid(sal_False);
}
void ScTable::SetColManualBreaks( const ::std::set<SCCOL>& rBreaks )
@@ -339,7 +339,7 @@ void ScTable::SetColManualBreaks( const ::std::set<SCCOL>& rBreaks )
maColManualBreaks = rBreaks;
InvalidatePageBreaks();
if (IsStreamValid())
- SetStreamValid(FALSE);
+ SetStreamValid(sal_False);
}
void ScTable::GetAllRowBreaks(set<SCROW>& rBreaks, bool bPage, bool bManual) const
@@ -935,13 +935,13 @@ SCROW ScTable::CountNonFilteredRows(SCROW nStartRow, SCROW nEndRow) const
namespace {
void lcl_syncFlags(ScFlatBoolColSegments& rColSegments, ScFlatBoolRowSegments& rRowSegments,
- BYTE* pColFlags, ScBitMaskCompressedArray< SCROW, BYTE>* pRowFlags, const BYTE nFlagMask)
+ sal_uInt8* pColFlags, ScBitMaskCompressedArray< SCROW, sal_uInt8>* pRowFlags, const sal_uInt8 nFlagMask)
{
using ::sal::static_int_cast;
- pRowFlags->AndValue(0, MAXROW, static_int_cast<BYTE>(~nFlagMask));
+ pRowFlags->AndValue(0, MAXROW, static_int_cast<sal_uInt8>(~nFlagMask));
for (SCCOL i = 0; i <= MAXCOL; ++i)
- pColFlags[i] &= static_int_cast<BYTE>(~nFlagMask);
+ pColFlags[i] &= static_int_cast<sal_uInt8>(~nFlagMask);
{
// row hidden flags.
@@ -954,7 +954,7 @@ void lcl_syncFlags(ScFlatBoolColSegments& rColSegments, ScFlatBoolRowSegments& r
break;
if (aData.mbValue)
- pRowFlags->OrValue(nRow, aData.mnRow2, static_int_cast<BYTE>(nFlagMask));
+ pRowFlags->OrValue(nRow, aData.mnRow2, static_int_cast<sal_uInt8>(nFlagMask));
nRow = aData.mnRow2 + 1;
}
@@ -988,15 +988,15 @@ void ScTable::SyncColRowFlags()
using ::sal::static_int_cast;
// Manual breaks.
- pRowFlags->AndValue(0, MAXROW, static_int_cast<BYTE>(~CR_MANUALBREAK));
+ pRowFlags->AndValue(0, MAXROW, static_int_cast<sal_uInt8>(~CR_MANUALBREAK));
for (SCCOL i = 0; i <= MAXCOL; ++i)
- pColFlags[i] &= static_int_cast<BYTE>(~CR_MANUALBREAK);
+ pColFlags[i] &= static_int_cast<sal_uInt8>(~CR_MANUALBREAK);
if (!maRowManualBreaks.empty())
{
for (set<SCROW>::const_iterator itr = maRowManualBreaks.begin(), itrEnd = maRowManualBreaks.end();
itr != itrEnd; ++itr)
- pRowFlags->OrValue(*itr, static_int_cast<BYTE>(CR_MANUALBREAK));
+ pRowFlags->OrValue(*itr, static_int_cast<sal_uInt8>(CR_MANUALBREAK));
}
if (!maColManualBreaks.empty())
@@ -1018,14 +1018,14 @@ void ScTable::SetPageSize( const Size& rSize )
if (aPageSizeTwips != rSize)
InvalidatePageBreaks();
- bPageSizeValid = TRUE;
+ bPageSizeValid = sal_True;
aPageSizeTwips = rSize;
}
else
- bPageSizeValid = FALSE;
+ bPageSizeValid = sal_False;
}
-BOOL ScTable::IsProtected() const
+sal_Bool ScTable::IsProtected() const
{
return pTabProtection.get() && pTabProtection->isProtected();
}
@@ -1038,7 +1038,7 @@ void ScTable::SetProtection(const ScTableProtection* pProtect)
pTabProtection.reset(NULL);
if (IsStreamValid())
- SetStreamValid(FALSE);
+ SetStreamValid(sal_False);
}
ScTableProtection* ScTable::GetProtection()
@@ -1094,20 +1094,20 @@ void ScTable::SetPageStyle( const String& rName )
{
SfxItemSet& rOldSet = pOldStyle->GetItemSet();
SfxItemSet& rNewSet = pNewStyle->GetItemSet();
- const USHORT nOldScale = GET_SCALEVALUE(rOldSet,ATTR_PAGE_SCALE);
- const USHORT nOldScaleToPages = GET_SCALEVALUE(rOldSet,ATTR_PAGE_SCALETOPAGES);
- const USHORT nNewScale = GET_SCALEVALUE(rNewSet,ATTR_PAGE_SCALE);
- const USHORT nNewScaleToPages = GET_SCALEVALUE(rNewSet,ATTR_PAGE_SCALETOPAGES);
+ const sal_uInt16 nOldScale = GET_SCALEVALUE(rOldSet,ATTR_PAGE_SCALE);
+ const sal_uInt16 nOldScaleToPages = GET_SCALEVALUE(rOldSet,ATTR_PAGE_SCALETOPAGES);
+ const sal_uInt16 nNewScale = GET_SCALEVALUE(rNewSet,ATTR_PAGE_SCALE);
+ const sal_uInt16 nNewScaleToPages = GET_SCALEVALUE(rNewSet,ATTR_PAGE_SCALETOPAGES);
if ( (nOldScale != nNewScale) || (nOldScaleToPages != nNewScaleToPages) )
- InvalidateTextWidth(NULL, NULL, FALSE, FALSE);
+ InvalidateTextWidth(NULL, NULL, sal_False, sal_False);
}
if ( pNewStyle ) // auch ohne den alten (fuer UpdateStdNames)
aPageStyle = aStrNew;
if (IsStreamValid())
- SetStreamValid(FALSE);
+ SetStreamValid(sal_False);
}
}
}
@@ -1115,11 +1115,11 @@ void ScTable::SetPageStyle( const String& rName )
void ScTable::PageStyleModified( const String& rNewName )
{
aPageStyle = rNewName;
- InvalidateTextWidth(NULL, NULL, FALSE, FALSE); // don't know what was in the style before
+ InvalidateTextWidth(NULL, NULL, sal_False, sal_False); // don't know what was in the style before
}
void ScTable::InvalidateTextWidth( const ScAddress* pAdrFrom, const ScAddress* pAdrTo,
- BOOL bNumFormatChanged, BOOL bBroadcast )
+ sal_Bool bNumFormatChanged, sal_Bool bBroadcast )
{
if ( pAdrFrom && !pAdrTo )
{