svx: sal_Bool->bool

Change-Id: I26a7bded5138d646c67ae396690659ee13ba9f36
This commit is contained in:
Noel Grandin 2014-03-05 16:23:36 +02:00
parent 37a2ed040e
commit aaee84c4c8
14 changed files with 137 additions and 138 deletions

View File

@ -445,7 +445,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet )
if ( rOldItem.GetPropLeft() != 100 )
{
m_pLeftIndent->SetRelative( sal_True );
m_pLeftIndent->SetRelative( true );
m_pLeftIndent->SetValue( rOldItem.GetPropLeft() );
}
else
@ -457,7 +457,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet )
if ( rOldItem.GetPropRight() != 100 )
{
m_pRightIndent->SetRelative( sal_True );
m_pRightIndent->SetRelative( true );
m_pRightIndent->SetValue( rOldItem.GetPropRight() );
}
else
@ -469,7 +469,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet )
if ( rOldItem.GetPropTxtFirstLineOfst() != 100 )
{
m_pFLineIndent->SetRelative( sal_True );
m_pFLineIndent->SetRelative( true );
m_pFLineIndent->SetValue( rOldItem.GetPropTxtFirstLineOfst() );
}
else
@ -515,7 +515,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet )
if ( rOldItem.GetPropUpper() != 100 )
{
m_pTopDist->SetRelative( sal_True );
m_pTopDist->SetRelative( true );
m_pTopDist->SetValue( rOldItem.GetPropUpper() );
}
else
@ -530,7 +530,7 @@ void SvxStdParagraphTabPage::Reset( const SfxItemSet& rSet )
if ( rOldItem.GetPropLower() != 100 )
{
m_pBottomDist->SetRelative( sal_True );
m_pBottomDist->SetRelative( true );
m_pBottomDist->SetValue( rOldItem.GetPropLower() );
}
else

View File

@ -31,9 +31,9 @@ private:
sal_uInt16 nRelMin;
sal_uInt16 nRelMax;
sal_uInt16 nRelStep;
sal_Bool bRelativeMode;
sal_Bool bRelative;
sal_Bool bNegativeEnabled;
bool bRelativeMode;
bool bRelative;
bool bNegativeEnabled;
protected:
void Modify();
@ -43,10 +43,10 @@ public:
void EnableRelativeMode( sal_uInt16 nMin = 50, sal_uInt16 nMax = 150,
sal_uInt16 nStep = 5 );
sal_Bool IsRelativeMode() const { return bRelativeMode; }
void SetRelative( sal_Bool bRelative = sal_False );
sal_Bool IsRelative() const { return bRelative; }
void EnableNegativeMode() {bNegativeEnabled = sal_True;}
bool IsRelativeMode() const { return bRelativeMode; }
void SetRelative( bool bRelative = false );
bool IsRelative() const { return bRelative; }
void EnableNegativeMode() {bNegativeEnabled = true;}
};

View File

@ -120,7 +120,7 @@ class SvxRubyDialog : public SfxModelessDialog
long nLastPos;
long nCurrentEdit;
sal_Bool bModified;
bool bModified;
com::sun::star::uno::Reference<com::sun::star::view::XSelectionChangeListener> xImpl;
SfxBindings* pBindings;
@ -148,8 +148,8 @@ class SvxRubyDialog : public SfxModelessDialog
long GetLastPos() const {return nLastPos;}
void SetLastPos(long nSet) {nLastPos = nSet;}
sal_Bool IsModified() const {return bModified;}
void SetModified(sal_Bool bSet) {bModified = bSet;}
bool IsModified() const {return bModified;}
void SetModified(bool bSet) {bModified = bSet;}
void EnableControls(bool bEnable);

View File

@ -61,8 +61,8 @@ class SVX_DLLPUBLIC SvxRuler: public Ruler, public SfxListener
boost::scoped_ptr<SvxRuler_Impl> mpRulerImpl;
sal_Bool bAppSetNullOffset :1;
sal_Bool bHorz :1;
bool bAppSetNullOffset :1;
bool bHorz :1;
long lLogicNullOffset; // in logic coordinates
long lAppNullOffset; // in logic coordinates
long lMinFrame; // minimal frame width in pixels
@ -97,16 +97,16 @@ class SVX_DLLPUBLIC SvxRuler: public Ruler, public SfxListener
long nDragOffset;
long nMaxLeft;
long nMaxRight;
sal_Bool bValid;
sal_Bool bListening;
sal_Bool bActive;
bool bValid;
bool bListening;
bool bActive;
bool mbCoarseSnapping;
bool mbSnapping;
void StartListening_Impl();
long GetCorrectedDragPos(sal_Bool bLeft = sal_True, sal_Bool bRight = sal_True );
void DrawLine_Impl(long &lTabPos, int, sal_Bool Horizontal=sal_True);
long GetCorrectedDragPos(bool bLeft = true, bool bRight = true );
void DrawLine_Impl(long &lTabPos, int, bool Horizontal = true);
sal_uInt16 GetObjectBordersOff(sal_uInt16 nIdx) const;
// page borders or surrounding frame
@ -224,18 +224,18 @@ protected:
// calculation of boundary values for object borders
// values refer to the page
virtual sal_Bool CalcLimits(long &nMax1, long &nMax2, sal_Bool bFirst) const;
sal_Bool IsActLastColumn(
sal_Bool bForceDontConsiderHidden = sal_False,
virtual bool CalcLimits(long &nMax1, long &nMax2, bool bFirst) const;
bool IsActLastColumn(
bool bForceDontConsiderHidden = false,
sal_uInt16 nAct=USHRT_MAX) const;
sal_Bool IsActFirstColumn(
sal_Bool bForceDontConsiderHidden = sal_False,
bool IsActFirstColumn(
bool bForceDontConsiderHidden = false,
sal_uInt16 nAct=USHRT_MAX) const;
sal_uInt16 GetActLeftColumn(
sal_Bool bForceDontConsiderHidden = sal_False,
bool bForceDontConsiderHidden = false,
sal_uInt16 nAct=USHRT_MAX ) const;
sal_uInt16 GetActRightColumn (
sal_Bool bForceDontConsiderHidden = sal_False,
bool bForceDontConsiderHidden = false,
sal_uInt16 nAct=USHRT_MAX ) const;
long CalcPropMaxRight(sal_uInt16 nCol = USHRT_MAX) const;
long GetPageWidth() const;
@ -272,8 +272,8 @@ public:
return lAppNullOffset;
}
void SetActive(sal_Bool bOn = sal_True);
sal_Bool IsActive() const
void SetActive(bool bOn = true);
bool IsActive() const
{
return bActive;
}
@ -284,7 +284,7 @@ public:
}
//#i24363# tab stops relative to indent
void SetTabsRelativeToIndent( sal_Bool bRel = sal_True );
void SetTabsRelativeToIndent( bool bRel = true );
};
#endif

View File

@ -127,7 +127,7 @@ struct SVX_DLLPUBLIC SvxColumnDescription
{
long nStart; /* Start of the column */
long nEnd; /* End of the column */
sal_Bool bVisible; /* Visibility */
bool bVisible; /* Visibility */
long nEndMin; //min. possible position of end
long nEndMax; //max. possible position of end
@ -136,10 +136,10 @@ struct SVX_DLLPUBLIC SvxColumnDescription
SvxColumnDescription(const SvxColumnDescription &rCopy);
SvxColumnDescription(long start, long end, sal_Bool bVis = sal_True);
SvxColumnDescription(long start, long end, bool bVis = true);
SvxColumnDescription(long start, long end,
long endMin, long endMax, sal_Bool bVis = sal_True);
long endMin, long endMax, bool bVis = true);
bool operator==(const SvxColumnDescription &rCmp) const;
bool operator!=(const SvxColumnDescription &rCmp) const;
@ -195,14 +195,14 @@ public:
void SetLeft(long aLeft);
void SetRight(long aRight);
sal_uInt16 GetActColumn() const;
sal_Bool IsFirstAct() const;
sal_Bool IsLastAct() const;
bool IsFirstAct() const;
bool IsLastAct() const;
long GetLeft();
long GetRight();
sal_Bool IsTable() const;
sal_Bool CalcOrtho() const;
void SetOrtho(sal_Bool bVal);
sal_Bool IsConsistent() const;
bool IsTable() const;
bool CalcOrtho() const;
void SetOrtho(bool bVal);
bool IsConsistent() const;
};
// class SvxObjectItem ---------------------------------------------------
@ -214,7 +214,7 @@ private:
long nEndX; /* End in x direction */
long nStartY; /* Start in y direction */
long nEndY; /* Ende in y direction */
sal_Bool bLimits; /* boundary limit control by the application */
bool bLimits; /* boundary limit control by the application */
protected:
virtual bool operator==( const SfxPoolItem& ) const;
@ -236,10 +236,10 @@ public:
TYPEINFO();
SvxObjectItem(long nStartX, long nEndX,
long nStartY, long nEndY,
sal_Bool bLimits = sal_False);
bool bLimits = false);
SvxObjectItem(const SvxObjectItem& rCopy);
sal_Bool HasLimits() const;
bool HasLimits() const;
long GetStartX() const;
long GetEndX() const;

View File

@ -313,9 +313,9 @@ void ViewShell::Activate(sal_Bool bIsMDIActivate)
gets the focus. */
if (mpHorizontalRuler.get() != NULL)
mpHorizontalRuler->SetActive(sal_True);
mpHorizontalRuler->SetActive(true);
if (mpVerticalRuler.get() != NULL)
mpVerticalRuler->SetActive(sal_True);
mpVerticalRuler->SetActive(true);
if (bIsMDIActivate)
{
@ -401,9 +401,9 @@ void ViewShell::Deactivate(sal_Bool bIsMDIActivate)
}
if (mpHorizontalRuler.get() != NULL)
mpHorizontalRuler->SetActive(sal_False);
mpHorizontalRuler->SetActive(false);
if (mpVerticalRuler.get() != NULL)
mpVerticalRuler->SetActive(sal_False);
mpVerticalRuler->SetActive(false);
SfxShell::Deactivate(bIsMDIActivate);
}
@ -733,7 +733,7 @@ void ViewShell::SetupRulers (void)
if ( mpVerticalRuler.get() != NULL )
{
nHRulerOfs = mpVerticalRuler->GetSizePixel().Width();
mpVerticalRuler->SetActive(sal_True);
mpVerticalRuler->SetActive(true);
mpVerticalRuler->Show();
}
}
@ -743,7 +743,7 @@ void ViewShell::SetupRulers (void)
if ( mpHorizontalRuler.get() != NULL )
{
mpHorizontalRuler->SetWinPos(nHRulerOfs);
mpHorizontalRuler->SetActive(sal_True);
mpHorizontalRuler->SetActive(true);
mpHorizontalRuler->Show();
}
}

View File

@ -27,9 +27,9 @@ SvxRelativeField::SvxRelativeField( Window* pParent, WinBits nBits)
, nRelMin(0)
, nRelMax(0)
, nRelStep(0)
, bRelativeMode(sal_False)
, bRelative(sal_False)
, bNegativeEnabled(sal_False)
, bRelativeMode(false)
, bRelative(false)
, bNegativeEnabled(false)
{
@ -51,7 +51,7 @@ void SvxRelativeField::Modify()
if ( bRelativeMode )
{
OUString aStr = GetText();
sal_Bool bNewMode = bRelative;
bool bNewMode = bRelative;
if ( bRelative )
{
@ -62,7 +62,7 @@ void SvxRelativeField::Modify()
if( ( ( *pStr < '0' ) || ( *pStr > '9' ) ) &&
( *pStr != '%' ) )
{
bNewMode = sal_False;
bNewMode = false;
break;
}
pStr++;
@ -71,7 +71,7 @@ void SvxRelativeField::Modify()
else
{
if ( aStr.indexOf( "%" ) != -1 )
bNewMode = sal_True;
bNewMode = true;
}
if ( bNewMode != bRelative )
@ -86,7 +86,7 @@ void SvxRelativeField::Modify()
void SvxRelativeField::EnableRelativeMode( sal_uInt16 nMin,
sal_uInt16 nMax, sal_uInt16 nStep )
{
bRelativeMode = sal_True;
bRelativeMode = true;
nRelMin = nMin;
nRelMax = nMax;
nRelStep = nStep;
@ -95,14 +95,14 @@ void SvxRelativeField::EnableRelativeMode( sal_uInt16 nMin,
void SvxRelativeField::SetRelative( sal_Bool bNewRelative )
void SvxRelativeField::SetRelative( bool bNewRelative )
{
Selection aSelection = GetSelection();
OUString aStr = GetText();
if ( bNewRelative )
{
bRelative = sal_True;
bRelative = true;
SetDecimalDigits( 0 );
SetMin( nRelMin );
SetMax( nRelMax );
@ -110,7 +110,7 @@ void SvxRelativeField::SetRelative( sal_Bool bNewRelative )
}
else
{
bRelative = sal_False;
bRelative = false;
SetDecimalDigits( 2 );
SetMin( bNegativeEnabled ? -9999 : 0 );
SetMax( 9999 );

View File

@ -412,7 +412,7 @@ void SvxRubyDialog::GetRubyText()
{
Sequence<PropertyValues>& aRubyValues = pImpl->GetRubyValues();
DBG_ASSERT(aRubyValues.getLength() > (i / 2 + nTempLastPos), "wrong index" );
SetModified(sal_True);
SetModified(true);
Sequence<PropertyValue> &rProps = aRubyValues.getArray()[i / 2 + nTempLastPos];
PropertyValue* pProps = rProps.getArray();
for(sal_Int32 nProp = 0; nProp < rProps.getLength(); nProp++)
@ -434,7 +434,7 @@ void SvxRubyDialog::Update()
m_pScrollSB->SetRange( Range(0, nLen > 4 ? nLen - 4 : 0));
m_pScrollSB->SetThumbPos(0);
SetLastPos(0);
SetModified(sal_False);
SetModified(false);
sal_Int16 nAdjust = -1;
sal_Int16 nPosition = -1;
@ -590,7 +590,7 @@ IMPL_LINK(SvxRubyDialog, AdjustHdl_Impl, ListBox*, pBox)
if ( pProps[nProp].Name == cRubyAdjust )
pProps[nProp].Value <<= nAdjust;
}
SetModified(sal_True);
SetModified(true);
}
m_pPreviewWin->Invalidate();
return 0;
@ -611,7 +611,7 @@ IMPL_LINK(SvxRubyDialog, PositionHdl_Impl, ListBox*, pBox)
if ( pProps[nProp].Name == cRubyIsAbove )
pProps[nProp].Value.setValue(&bAbove, rType);
}
SetModified(sal_True);
SetModified(true);
}
m_pPreviewWin->Invalidate();
return 0;
@ -635,7 +635,7 @@ IMPL_LINK_NOARG(SvxRubyDialog, CharStyleHdl_Impl)
pProps[nProp].Value <<= sStyleName;
}
}
SetModified(sal_True);
SetModified(true);
}
return 0;
}

View File

@ -521,20 +521,20 @@ const SvxColumnItem& SvxColumnItem::operator=(const SvxColumnItem& rCopy)
return *this;
}
sal_Bool SvxColumnItem::CalcOrtho() const
bool SvxColumnItem::CalcOrtho() const
{
const sal_uInt16 nCount = Count();
DBG_ASSERT(nCount >= 2, "no columns");
if(nCount < 2)
return sal_False;
return false;
long nColWidth = (*this)[0].GetWidth();
for(sal_uInt16 i = 1; i < nCount; ++i) {
if( (*this)[i].GetWidth() != nColWidth)
return sal_False;
return false;
}
//!! Wide divider
return sal_True;
return true;
}
bool SvxColumnItem::QueryValue( com::sun::star::uno::Any& rVal, sal_uInt8 nMemberId ) const
@ -653,12 +653,12 @@ sal_uInt16 SvxColumnItem::GetActColumn() const
return nActColumn;
}
sal_Bool SvxColumnItem::IsFirstAct() const
bool SvxColumnItem::IsFirstAct() const
{
return nActColumn == 0;
}
sal_Bool SvxColumnItem::IsLastAct() const
bool SvxColumnItem::IsLastAct() const
{
return nActColumn == Count() - 1;
}
@ -673,7 +673,7 @@ long SvxColumnItem::GetRight()
return nRight;
}
sal_Bool SvxColumnItem::IsTable() const
bool SvxColumnItem::IsTable() const
{
return bTable;
}
@ -683,7 +683,7 @@ sal_Bool SvxColumnItem::IsTable() const
SvxColumnDescription::SvxColumnDescription() :
nStart (0),
nEnd (0),
bVisible (sal_True),
bVisible (true),
nEndMin (0),
nEndMax (0)
{}
@ -696,7 +696,7 @@ SvxColumnDescription::SvxColumnDescription(const SvxColumnDescription &rCopy) :
nEndMax (rCopy.nEndMax)
{}
SvxColumnDescription::SvxColumnDescription(long start, long end, sal_Bool bVis) :
SvxColumnDescription::SvxColumnDescription(long start, long end, bool bVis) :
nStart (start),
nEnd (end),
bVisible (bVis),
@ -704,7 +704,7 @@ SvxColumnDescription::SvxColumnDescription(long start, long end, sal_Bool bVis)
nEndMax (0)
{}
SvxColumnDescription::SvxColumnDescription(long start, long end, long endMin, long endMax, sal_Bool bVis) :
SvxColumnDescription::SvxColumnDescription(long start, long end, long endMin, long endMax, bool bVis) :
nStart (start),
nEnd (end),
bVisible (bVis),
@ -732,12 +732,12 @@ long SvxColumnDescription::GetWidth() const
}
/* SvxColumnItem */
void SvxColumnItem::SetOrtho(sal_Bool bVal)
void SvxColumnItem::SetOrtho(bool bVal)
{
bOrtho = bVal;
}
sal_Bool SvxColumnItem::IsConsistent() const
bool SvxColumnItem::IsConsistent() const
{
return nActColumn < aColumns.size();
}
@ -773,7 +773,7 @@ SfxPoolItem* SvxObjectItem::Clone(SfxItemPool *) const
}
SvxObjectItem::SvxObjectItem( long nSX, long nEX,
long nSY, long nEY, sal_Bool limits ) :
long nSY, long nEY, bool limits ) :
SfxPoolItem (SID_RULER_OBJECT),
nStartX (nSX),
nEndX (nEX),
@ -846,7 +846,7 @@ bool SvxObjectItem::PutValue( const com::sun::star::uno::Any& rVal, sal_uInt8 nM
return bRet;
}
sal_Bool SvxObjectItem::HasLimits() const
bool SvxObjectItem::HasLimits() const
{
return bLimits;
}

View File

@ -209,7 +209,7 @@ SvxRuler::SvxRuler(
pCtrlItem(new SvxRulerItem* [CTRL_ITEM_COUNT]),
pEditWin(pWin),
mpRulerImpl(new SvxRuler_Impl),
bAppSetNullOffset(sal_False), // Is the 0-offset of the ruler set by the application?
bAppSetNullOffset(false), // Is the 0-offset of the ruler set by the application?
lLogicNullOffset(0),
lAppNullOffset(LONG_MAX),
lMinFrame(5),
@ -226,9 +226,9 @@ SvxRuler::SvxRuler(
nDragOffset(0),
nMaxLeft(0),
nMaxRight(0),
bValid(sal_False),
bListening(sal_False),
bActive(sal_True),
bValid(false),
bListening(false),
bActive(true),
mbCoarseSnapping(false),
mbSnapping(true)
@ -246,12 +246,12 @@ SvxRuler::SvxRuler(
pCtrlItem[i++] = new SvxRulerItem(SID_RULER_LR_MIN_MAX, *this, rBindings);
if((nWinStyle & WB_VSCROLL) == WB_VSCROLL)
{
bHorz = sal_False;
bHorz = false;
pCtrlItem[i++] = new SvxRulerItem(SID_ATTR_LONG_ULSPACE, *this, rBindings);
}
else
{
bHorz = sal_True;
bHorz = true;
pCtrlItem[i++] = new SvxRulerItem(SID_ATTR_LONG_LRSPACE, *this, rBindings);
}
@ -664,9 +664,9 @@ void SvxRuler::StartListening_Impl()
{
if(!bListening)
{
bValid = sal_False;
bValid = false;
StartListening(*pBindings);
bListening = sal_True;
bListening = true;
}
}
@ -1211,7 +1211,7 @@ void SvxRuler::Update(const SvxObjectItem *pItem) // new value for objects
void SvxRuler::SetNullOffsetLogic(long lVal) // Setting of the logic NullOffsets
{
lAppNullOffset = lLogicNullOffset - lVal;
bAppSetNullOffset = sal_True;
bAppSetNullOffset = true;
Ruler::SetNullOffset(ConvertSizePixel(lVal));
Update();
}
@ -1370,7 +1370,7 @@ long SvxRuler::GetRightFrameMargin() const
SVXRULER_SUPPORT_NEGATIVE_MARGINS )
#define TAB_FLAG ( mpColumnItem.get() && mpColumnItem->IsTable() )
long SvxRuler::GetCorrectedDragPos( sal_Bool bLeft, sal_Bool bRight )
long SvxRuler::GetCorrectedDragPos( bool bLeft, bool bRight )
{
/*
Corrects the position within the calculated limits. The limit values are in
@ -1405,7 +1405,7 @@ void ModifyTabs_Impl( sal_uInt16 nCount, // Number of Tabs
void SvxRuler::DragMargin1()
{
/* Dragging the left edge of frame */
long aDragPosition = GetCorrectedDragPos( !TAB_FLAG || !NEG_FLAG, sal_True );
long aDragPosition = GetCorrectedDragPos( !TAB_FLAG || !NEG_FLAG, true );
aDragPosition = MakePositionSticky(aDragPosition, GetRightFrameMargin(), false);
@ -1537,7 +1537,7 @@ void SvxRuler::AdjustMargin1(long lInputDiff)
void SvxRuler::DragMargin2()
{
/* Dragging the right edge of frame */
long aDragPosition = GetCorrectedDragPos( sal_True, !TAB_FLAG || !NEG_FLAG);
long aDragPosition = GetCorrectedDragPos( true, !TAB_FLAG || !NEG_FLAG);
aDragPosition = MakePositionSticky(aDragPosition, GetLeftFrameMargin(), false);
long lDiff = aDragPosition - GetMargin2();
@ -1602,7 +1602,7 @@ void SvxRuler::DragIndents()
DrawLine_Impl(lTabPos, 1, bHorz);
}
void SvxRuler::DrawLine_Impl(long& lTabPosition, int nNew, sal_Bool bHorizontal)
void SvxRuler::DrawLine_Impl(long& lTabPosition, int nNew, bool bHorizontal)
{
/*
Output routine for the ledger line when moving tabs, tables and other
@ -1662,7 +1662,7 @@ void SvxRuler::DrawLine_Impl(long& lTabPosition, int nNew, sal_Bool bHorizontal)
void SvxRuler::DragTabs()
{
/* Dragging of Tabs */
long aDragPosition = GetCorrectedDragPos(sal_True, sal_False);
long aDragPosition = GetCorrectedDragPos(true, false);
aDragPosition = MakePositionSticky(aDragPosition, GetLeftFrameMargin());
sal_uInt16 nIdx = GetDragAryPos() + TAB_GAP;
@ -1715,7 +1715,7 @@ void SvxRuler::DragTabs()
SetTabs(nTabCount, &mpTabs[0] + TAB_GAP);
}
void SvxRuler::SetActive(sal_Bool bOn)
void SvxRuler::SetActive(bool bOn)
{
if(bOn)
{
@ -2103,17 +2103,17 @@ void SvxRuler::ApplyIndents()
long nLeftMargin = ConvertPosLogic(mpIndents[INDENT_LEFT_MARGIN].nPos);
long nRightMargin = ConvertPosLogic(mpIndents[INDENT_RIGHT_MARGIN].nPos);
if(mpColumnItem.get() && ((bRTL && !IsActLastColumn(sal_True)) || (!bRTL && !IsActFirstColumn(sal_True))))
if(mpColumnItem.get() && ((bRTL && !IsActLastColumn(true)) || (!bRTL && !IsActFirstColumn(true))))
{
if(bRTL)
{
long nRightColumn = GetActRightColumn(sal_True);
long nRightColumn = GetActRightColumn(true);
long nRightBorder = ConvertPosLogic(mpBorders[nRightColumn].nPos);
nNewTxtLeft = nRightBorder - nLeftMargin - lAppNullOffset;
}
else
{
long nLeftColumn = GetActLeftColumn(sal_True);
long nLeftColumn = GetActLeftColumn(true);
long nLeftBorder = ConvertPosLogic(mpBorders[nLeftColumn].nPos + mpBorders[nLeftColumn].nWidth);
nNewTxtLeft = nLeftMargin - nLeftBorder - lAppNullOffset;
}
@ -2137,17 +2137,17 @@ void SvxRuler::ApplyIndents()
else
nNewFirstLineOffset = nFirstLine - nLeftMargin - lAppNullOffset;
if(mpColumnItem.get() && ((!bRTL && !IsActLastColumn(sal_True)) || (bRTL && !IsActFirstColumn(sal_True))))
if(mpColumnItem.get() && ((!bRTL && !IsActLastColumn(true)) || (bRTL && !IsActFirstColumn(true))))
{
if(bRTL)
{
long nLeftColumn = GetActLeftColumn(sal_True);
long nLeftColumn = GetActLeftColumn(true);
long nLeftBorder = ConvertPosLogic(mpBorders[nLeftColumn].nPos + mpBorders[nLeftColumn].nWidth);
nNewRight = nRightMargin - nLeftBorder - lAppNullOffset;
}
else
{
long nRightColumn = GetActRightColumn(sal_True);
long nRightColumn = GetActRightColumn(true);
long nRightBorder = ConvertPosLogic(mpBorders[nRightColumn].nPos);
nNewRight = nRightBorder - nRightMargin - lAppNullOffset;
}
@ -2591,9 +2591,9 @@ void SvxRuler::Click()
}
}
sal_Bool SvxRuler::CalcLimits ( long& nMax1, // minimum value to be set
long& nMax2, // minimum value to be set
sal_Bool ) const
bool SvxRuler::CalcLimits ( long& nMax1, // minimum value to be set
long& nMax2, // minimum value to be set
bool ) const
{
/*
Default implementation of the virtual function; the application can be
@ -2601,7 +2601,7 @@ sal_Bool SvxRuler::CalcLimits ( long& nMax1, // minimum value to be set
*/
nMax1 = LONG_MIN;
nMax2 = LONG_MAX;
return sal_False;
return false;
}
void SvxRuler::CalcMinMax()
@ -2827,9 +2827,9 @@ void SvxRuler::CalcMinMax()
{
//nIdx contains the position of the currently moved item
//next visible separator on the left
sal_uInt16 nLeftCol=GetActLeftColumn(sal_False, nIdx);
sal_uInt16 nLeftCol=GetActLeftColumn(false, nIdx);
//next visible separator on the right
sal_uInt16 nRightCol=GetActRightColumn(sal_False, nIdx);
sal_uInt16 nRightCol=GetActRightColumn(false, nIdx);
//next separator on the left - regardless if visible or not
sal_uInt16 nActLeftCol=GetActLeftColumn();
//next separator on the right - regardless if visible or not
@ -2954,7 +2954,7 @@ void SvxRuler::CalcMinMax()
{
nMaxRight = lNullPix + mpBorders[nRightCol].nPos;
sal_uInt16 nNotHiddenRightCol =
GetActRightColumn(sal_True, nIdx);
GetActRightColumn(true, nIdx);
if( nActLeftCol == nIdx )
{
@ -3091,8 +3091,8 @@ void SvxRuler::CalcMinMax()
nMaxRight = lNullPix + std::min(GetFirstLineIndent(), GetLeftIndent()) - lMinFrame;
if(mpColumnItem.get())
{
sal_uInt16 nRightCol=GetActRightColumn( sal_True );
if(!IsActLastColumn( sal_True ))
sal_uInt16 nRightCol=GetActRightColumn( true );
if(!IsActLastColumn( true ))
nMaxRight += mpBorders[nRightCol].nPos;
else
nMaxRight += GetMargin2();
@ -3110,8 +3110,8 @@ void SvxRuler::CalcMinMax()
nMaxRight = lNullPix;
if(mpColumnItem.get())
{
sal_uInt16 nRightCol=GetActRightColumn( sal_True );
if(!IsActLastColumn( sal_True ))
sal_uInt16 nRightCol=GetActRightColumn( true );
if(!IsActLastColumn( true ))
nMaxRight += mpBorders[nRightCol].nPos;
else
nMaxRight += GetMargin2();
@ -3376,8 +3376,8 @@ void SvxRuler::Notify(SfxBroadcaster&, const SfxHint& rHint)
{
Update();
EndListening(*pBindings);
bValid = sal_True;
bListening = sal_False;
bValid = true;
bListening = false;
}
}
@ -3482,7 +3482,7 @@ void SvxRuler::Command( const CommandEvent& rCommandEvent )
}
sal_uInt16 SvxRuler::GetActRightColumn(
sal_Bool bForceDontConsiderHidden,
bool bForceDontConsiderHidden,
sal_uInt16 nAct ) const
{
if( nAct == USHRT_MAX )
@ -3504,7 +3504,7 @@ sal_uInt16 SvxRuler::GetActRightColumn(
}
sal_uInt16 SvxRuler::GetActLeftColumn(
sal_Bool bForceDontConsiderHidden,
bool bForceDontConsiderHidden,
sal_uInt16 nAct ) const
{
if(nAct == USHRT_MAX)
@ -3525,15 +3525,15 @@ sal_uInt16 SvxRuler::GetActLeftColumn(
return USHRT_MAX;
}
sal_Bool SvxRuler::IsActLastColumn(
sal_Bool bForceDontConsiderHidden,
bool SvxRuler::IsActLastColumn(
bool bForceDontConsiderHidden,
sal_uInt16 nAct) const
{
return GetActRightColumn(bForceDontConsiderHidden, nAct) == USHRT_MAX;
}
sal_Bool SvxRuler::IsActFirstColumn(
sal_Bool bForceDontConsiderHidden,
bool SvxRuler::IsActFirstColumn(
bool bForceDontConsiderHidden,
sal_uInt16 nAct) const
{
return GetActLeftColumn(bForceDontConsiderHidden, nAct) == USHRT_MAX;
@ -3609,7 +3609,7 @@ long SvxRuler::CalcPropMaxRight(sal_uInt16 nCol) const
}
else
{
nRight = GetActRightColumn(sal_False, nActCol);
nRight = GetActRightColumn(false, nActCol);
}
long lWidth;
@ -3638,11 +3638,11 @@ long SvxRuler::CalcPropMaxRight(sal_uInt16 nCol) const
if(mpColumnItem->IsTable())
{
sal_uInt16 nVisCols = 0;
for(sal_uInt16 i = GetActRightColumn(sal_False, nCol); i < mpBorders.size();)
for(sal_uInt16 i = GetActRightColumn(false, nCol); i < mpBorders.size();)
{
if((*mpColumnItem.get())[i].bVisible)
nVisCols++;
i = GetActRightColumn(sal_False, i);
i = GetActRightColumn(false, i);
}
return GetMargin2() - GetMargin1() - (nVisCols + 1) * lMinFrame;
}
@ -3659,7 +3659,7 @@ long SvxRuler::CalcPropMaxRight(sal_uInt16 nCol) const
}
// Tab stops relative to indent (#i24363#)
void SvxRuler::SetTabsRelativeToIndent( sal_Bool bRel )
void SvxRuler::SetTabsRelativeToIndent( bool bRel )
{
mpRulerImpl->bIsTabsRelativeToIndent = bRel;
}

View File

@ -132,8 +132,8 @@ SwInputWindow::~SwInputWindow()
// wake rulers
if(pView)
{
pView->GetHRuler().SetActive( sal_True );
pView->GetVRuler().SetActive( sal_True );
pView->GetHRuler().SetActive( true );
pView->GetVRuler().SetActive( true );
}
delete pMgr;
if(pWrtShell)
@ -193,8 +193,8 @@ void SwInputWindow::ShowWin()
// stop rulers
if(pView)
{
pView->GetHRuler().SetActive( sal_False );
pView->GetVRuler().SetActive( sal_False );
pView->GetHRuler().SetActive( false );
pView->GetVRuler().SetActive( false );
OSL_ENSURE(pWrtShell, "no WrtShell!");
// Cursor in table

View File

@ -877,8 +877,8 @@ SwView::SwView( SfxViewFrame *_pFrame, SfxViewShell* pOldSh )
bool bOld = bNoInterrupt;
bNoInterrupt = true;
m_pHRuler->SetActive( sal_True );
m_pVRuler->SetActive( sal_True );
m_pHRuler->SetActive( true );
m_pVRuler->SetActive( true );
SfxViewFrame* pViewFrame = GetViewFrame();
if( pViewFrame->GetFrame().GetParentFrame())

View File

@ -67,8 +67,8 @@ void SwView::Activate(sal_Bool bMDIActivate)
m_pWrtShell->MakeSelVisible();
m_bMakeSelectionVisible = sal_False;
}
m_pHRuler->SetActive( sal_True );
m_pVRuler->SetActive( sal_True );
m_pHRuler->SetActive( true );
m_pVRuler->SetActive( true );
if ( bMDIActivate )
{
@ -126,8 +126,8 @@ void SwView::Deactivate(sal_Bool bMDIActivate)
{
m_pWrtShell->ShLooseFcs(); // Selections invisible
m_pHRuler->SetActive( sal_False );
m_pVRuler->SetActive( sal_False );
m_pHRuler->SetActive( false );
m_pVRuler->SetActive( false );
}
SfxViewShell::Deactivate(bMDIActivate);
}

View File

@ -92,7 +92,7 @@ static void lcl_FillSvxColumn(const SwFmtCol& rCol,
nWidth = static_cast< sal_uInt16 >(nWidth + rCol.CalcColWidth(i, nTotalWidth));
const sal_uInt16 nEnd = sal_uInt16(nWidth - pCol->GetRight() + nDistance);
SvxColumnDescription aColDesc(nStart, nEnd, sal_True);
SvxColumnDescription aColDesc(nStart, nEnd, true);
rColItem.Append(aColDesc);
}
}
@ -1478,7 +1478,7 @@ void SwView::StateTabWin(SfxItemSet& rSet)
nStart = nEnd;
}
SvxColumnDescription aColDesc(nStart,
aTabCols.GetRight() - aTabCols.GetLeft(), sal_True);
aTabCols.GetRight() - aTabCols.GetLeft(), true);
aColItem.Append(aColDesc);
}
else
@ -1494,8 +1494,7 @@ void SwView::StateTabWin(SfxItemSet& rSet)
nStart = nEnd;
}
SvxColumnDescription aColDesc(nStart, aTabCols.GetRight() - aTabCols.GetLeft(),
0, 0,
sal_True);
0, 0, true);
aColItem.Append(aColDesc);
}
rSet.Put(aColItem, nWhich);
@ -1730,7 +1729,7 @@ void SwView::StateTabWin(SfxItemSet& rSet)
SvxColumnDescription aColDesc( nStart, nEnd,
aTabCols.GetRight(), aTabCols.GetRight(),
sal_False );
false );
aColItem.Append(aColDesc);
rSet.Put(aColItem, nWhich);