summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/crsr/crsrsh.cxx3
-rw-r--r--sw/source/core/frmedt/fews.cxx12
-rw-r--r--sw/source/core/layout/flycnt.cxx12
-rw-r--r--sw/source/core/layout/pagechg.cxx4
-rw-r--r--sw/source/core/layout/wsfrm.cxx6
-rw-r--r--sw/source/core/text/itradj.cxx4
-rw-r--r--sw/source/core/text/itrform2.cxx62
-rw-r--r--sw/source/ui/misc/outline.cxx2
-rw-r--r--sw/source/uibase/docvw/srcedtw.cxx6
9 files changed, 57 insertions, 54 deletions
diff --git a/sw/source/core/crsr/crsrsh.cxx b/sw/source/core/crsr/crsrsh.cxx
index 565acb6d60fd..f08c1fe6e199 100644
--- a/sw/source/core/crsr/crsrsh.cxx
+++ b/sw/source/core/crsr/crsrsh.cxx
@@ -2438,8 +2438,7 @@ OUString SwCursorShell::GetSelText() const
aText = buf.makeStringAndClear();
}
}
- else
- if( m_pCurrentCursor->GetPoint()->nNode.GetIndex() ==
+ else if( m_pCurrentCursor->GetPoint()->nNode.GetIndex() ==
m_pCurrentCursor->GetMark()->nNode.GetIndex() )
{
SwTextNode* pTextNd = m_pCurrentCursor->GetNode().GetTextNode();
diff --git a/sw/source/core/frmedt/fews.cxx b/sw/source/core/frmedt/fews.cxx
index 8b2247eacc05..8b2dfc35fdd5 100644
--- a/sw/source/core/frmedt/fews.cxx
+++ b/sw/source/core/frmedt/fews.cxx
@@ -242,7 +242,8 @@ FrameTypeFlags SwFEShell::GetFrameType( const Point *pPt, bool bStopAtFly ) cons
{
switch ( pFrame->GetType() )
{
- case SwFrameType::Column: if( pFrame->GetUpper()->IsSctFrame() )
+ case SwFrameType::Column:
+ if( pFrame->GetUpper()->IsSctFrame() )
{
// Check, if isn't not only a single column
// from a section with footnotes at the end.
@@ -254,17 +255,20 @@ FrameTypeFlags SwFEShell::GetFrameType( const Point *pPt, bool bStopAtFly ) cons
else // only pages and frame columns
nReturn |= FrameTypeFlags::COLUMN;
break;
- case SwFrameType::Page: nReturn |= FrameTypeFlags::PAGE;
+ case SwFrameType::Page:
+ nReturn |= FrameTypeFlags::PAGE;
if( static_cast<const SwPageFrame*>(pFrame)->IsFootnotePage() )
nReturn |= FrameTypeFlags::FTNPAGE;
break;
case SwFrameType::Header: nReturn |= FrameTypeFlags::HEADER; break;
case SwFrameType::Footer: nReturn |= FrameTypeFlags::FOOTER; break;
- case SwFrameType::Body: if( pFrame->GetUpper()->IsPageFrame() ) // not for ColumnFrames
+ case SwFrameType::Body:
+ if( pFrame->GetUpper()->IsPageFrame() ) // not for ColumnFrames
nReturn |= FrameTypeFlags::BODY;
break;
case SwFrameType::Ftn: nReturn |= FrameTypeFlags::FOOTNOTE; break;
- case SwFrameType::Fly: if( static_cast<const SwFlyFrame*>(pFrame)->IsFlyLayFrame() )
+ case SwFrameType::Fly:
+ if( static_cast<const SwFlyFrame*>(pFrame)->IsFlyLayFrame() )
nReturn |= FrameTypeFlags::FLY_FREE;
else if ( static_cast<const SwFlyFrame*>(pFrame)->IsFlyAtContentFrame() )
nReturn |= FrameTypeFlags::FLY_ATCNT;
diff --git a/sw/source/core/layout/flycnt.cxx b/sw/source/core/layout/flycnt.cxx
index 7f9b462159f6..9163098fee18 100644
--- a/sw/source/core/layout/flycnt.cxx
+++ b/sw/source/core/layout/flycnt.cxx
@@ -675,13 +675,13 @@ static const SwFrame * lcl_CalcDownDist( SwDistance &rRet,
nPrtHeight = pLay->getFrameArea().Left() + pLay->getFramePrintArea().Left()
+ pLay->getFramePrintArea().Width() - pSect->getFrameArea().Left()
- pSect->getFrameArea().Width();
- }
- else
- {
- nFrameTop = pSect->getFrameArea().Left();
- nPrtHeight = pSect->getFrameArea().Left() - pLay->getFrameArea().Left()
+ }
+ else
+ {
+ nFrameTop = pSect->getFrameArea().Left();
+ nPrtHeight = pSect->getFrameArea().Left() - pLay->getFrameArea().Left()
- pLay->getFramePrintArea().Left();
- }
+ }
}
else
{
diff --git a/sw/source/core/layout/pagechg.cxx b/sw/source/core/layout/pagechg.cxx
index 6d1bd3e0fa45..94151fa3671f 100644
--- a/sw/source/core/layout/pagechg.cxx
+++ b/sw/source/core/layout/pagechg.cxx
@@ -346,8 +346,8 @@ void SwPageFrame::CheckDirection( bool bVert )
if(SvxFrameDirection::Vertical_RL_TB == nDir)
mbVertLR = false;
- else if(SvxFrameDirection::Vertical_LR_TB==nDir)
- mbVertLR = true;
+ else if(SvxFrameDirection::Vertical_LR_TB==nDir)
+ mbVertLR = true;
}
}
diff --git a/sw/source/core/layout/wsfrm.cxx b/sw/source/core/layout/wsfrm.cxx
index 36ae515e767a..c8648be49808 100644
--- a/sw/source/core/layout/wsfrm.cxx
+++ b/sw/source/core/layout/wsfrm.cxx
@@ -350,12 +350,12 @@ void SwFrame::CheckDir( SvxFrameDirection nDir, bool bVert, bool bOnlyBiDi, bool
mbVertLR = false;
}
else
- {
+ {
mbVertical = true;
if(SvxFrameDirection::Vertical_RL_TB == nDir)
mbVertLR = false;
- else if(SvxFrameDirection::Vertical_LR_TB==nDir)
- mbVertLR = true;
+ else if(SvxFrameDirection::Vertical_LR_TB==nDir)
+ mbVertLR = true;
}
}
else
diff --git a/sw/source/core/text/itradj.cxx b/sw/source/core/text/itradj.cxx
index 79cd1978dbdf..b4fca7913754 100644
--- a/sw/source/core/text/itradj.cxx
+++ b/sw/source/core/text/itradj.cxx
@@ -632,8 +632,8 @@ void SwTextAdjuster::CalcFlyAdjust( SwLineLayout *pCurrent )
if( !pPos->IsMarginPortion() )
static_cast<SwGluePortion*>(pPos)->MoveHalfGlue( pGlue );
}
- }
- else
+ }
+ else
static_cast<SwGluePortion*>(pPos)->MoveHalfGlue( pGlue );
}
}
diff --git a/sw/source/core/text/itrform2.cxx b/sw/source/core/text/itrform2.cxx
index f0f3646a38da..dddeed9b40df 100644
--- a/sw/source/core/text/itrform2.cxx
+++ b/sw/source/core/text/itrform2.cxx
@@ -1332,43 +1332,43 @@ SwLinePortion *SwTextFormatter::NewPortion( SwTextFormatInfo &rInf )
SAL_FALLTHROUGH;
default :
{
- SwTabPortion* pLastTabPortion = rInf.GetLastTab();
- if ( pLastTabPortion && cChar == rInf.GetTabDecimal() )
- {
- // Abandon dec. tab position if line is full
- // We have a decimal tab portion in the line and the next character has to be
- // aligned at the tab stop position. We store the width from the beginning of
- // the tab stop portion up to the portion containing the decimal separator:
- if (GetTextFrame()->GetDoc().getIDocumentSettingAccess().get(DocumentSettingId::TAB_COMPAT) /*rInf.GetVsh()->IsTabCompat();*/ &&
- POR_TABDECIMAL == pLastTabPortion->GetWhichPor() )
+ SwTabPortion* pLastTabPortion = rInf.GetLastTab();
+ if ( pLastTabPortion && cChar == rInf.GetTabDecimal() )
{
- OSL_ENSURE( rInf.X() >= pLastTabPortion->GetFix(), "Decimal tab stop position cannot be calculated" );
- const sal_uInt16 nWidthOfPortionsUpToDecimalPosition = static_cast<sal_uInt16>(rInf.X() - pLastTabPortion->GetFix() );
- static_cast<SwTabDecimalPortion*>(pLastTabPortion)->SetWidthOfPortionsUpToDecimalPosition( nWidthOfPortionsUpToDecimalPosition );
- rInf.SetTabDecimal( 0 );
+ // Abandon dec. tab position if line is full
+ // We have a decimal tab portion in the line and the next character has to be
+ // aligned at the tab stop position. We store the width from the beginning of
+ // the tab stop portion up to the portion containing the decimal separator:
+ if (GetTextFrame()->GetDoc().getIDocumentSettingAccess().get(DocumentSettingId::TAB_COMPAT) /*rInf.GetVsh()->IsTabCompat();*/ &&
+ POR_TABDECIMAL == pLastTabPortion->GetWhichPor() )
+ {
+ OSL_ENSURE( rInf.X() >= pLastTabPortion->GetFix(), "Decimal tab stop position cannot be calculated" );
+ const sal_uInt16 nWidthOfPortionsUpToDecimalPosition = static_cast<sal_uInt16>(rInf.X() - pLastTabPortion->GetFix() );
+ static_cast<SwTabDecimalPortion*>(pLastTabPortion)->SetWidthOfPortionsUpToDecimalPosition( nWidthOfPortionsUpToDecimalPosition );
+ rInf.SetTabDecimal( 0 );
+ }
+ else
+ rInf.SetFull( rInf.GetLastTab()->Format( rInf ) );
}
- else
- rInf.SetFull( rInf.GetLastTab()->Format( rInf ) );
- }
- if( rInf.GetRest() )
- {
- if( rInf.IsFull() )
+ if( rInf.GetRest() )
{
- rInf.SetNewLine(true);
- return nullptr;
+ if( rInf.IsFull() )
+ {
+ rInf.SetNewLine(true);
+ return nullptr;
+ }
+ pPor = rInf.GetRest();
+ rInf.SetRest(nullptr);
}
- pPor = rInf.GetRest();
- rInf.SetRest(nullptr);
- }
- else
- {
- if( rInf.IsFull() )
- return nullptr;
- pPor = NewTextPortion( rInf );
+ else
+ {
+ if( rInf.IsFull() )
+ return nullptr;
+ pPor = NewTextPortion( rInf );
+ }
+ break;
}
- break;
- }
}
// if a portion is created despite there being a pending RestPortion,
diff --git a/sw/source/ui/misc/outline.cxx b/sw/source/ui/misc/outline.cxx
index 8cf7246243d7..a5b6b4576bda 100644
--- a/sw/source/ui/misc/outline.cxx
+++ b/sw/source/ui/misc/outline.cxx
@@ -319,7 +319,7 @@ short SwOutlineTabDialog::Ok()
const SfxPoolItem & rItem =
rTextColl.GetFormatAttr(RES_PARATR_NUMRULE, false);
- if (static_cast<sal_uInt8>(GetLevel(rTextColl.GetName())) == MAXLEVEL)
+ if (static_cast<sal_uInt8>(GetLevel(rTextColl.GetName())) == MAXLEVEL)
{
if(rTextColl.IsAssignedToListLevelOfOutlineStyle())
{
diff --git a/sw/source/uibase/docvw/srcedtw.cxx b/sw/source/uibase/docvw/srcedtw.cxx
index dcf094fe22fb..288bcd774716 100644
--- a/sw/source/uibase/docvw/srcedtw.cxx
+++ b/sw/source/uibase/docvw/srcedtw.cxx
@@ -443,9 +443,9 @@ void TextViewOutWin::Command( const CommandEvent& rCEvt )
default:
if ( pTextView )
- pTextView->Command( rCEvt );
- else
- Window::Command(rCEvt);
+ pTextView->Command( rCEvt );
+ else
+ Window::Command(rCEvt);
}
}