summaryrefslogtreecommitdiff
path: root/svx/source/dialog/paraprev.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'svx/source/dialog/paraprev.cxx')
-rw-r--r--svx/source/dialog/paraprev.cxx51
1 files changed, 3 insertions, 48 deletions
diff --git a/svx/source/dialog/paraprev.cxx b/svx/source/dialog/paraprev.cxx
index 3a4d2bd14651..d10b11b28688 100644
--- a/svx/source/dialog/paraprev.cxx
+++ b/svx/source/dialog/paraprev.cxx
@@ -214,12 +214,8 @@ void SvxParaPrevWindow::DrawParagraph(vcl::RenderContext& rRenderContext)
ParaPrevWindow::ParaPrevWindow() :
nLeftMargin ( 0 ),
nRightMargin ( 0 ),
- nFirstLineOfst ( 0 ),
- nUpper ( 0 ),
- nLower ( 0 ),
eAdjust ( SvxAdjust::Left ),
- eLastLine ( SvxAdjust::Left ),
- eLine ( SvxPrevLineSpace::N1 )
+ eLastLine ( SvxAdjust::Left )
{
aSize = Size(11905, 16837);
}
@@ -272,8 +268,6 @@ void ParaPrevWindow::DrawParagraph(vcl::RenderContext& rRenderContext)
if (i == 3)
{
rRenderContext.SetFillColor(COL_GRAY);
- auto nTop = nUpper * aLineSiz.Height() / aSize.Height();
- aPnt.AdjustY(nTop * 2 );
}
if (i == 6 )
@@ -282,45 +276,12 @@ void ParaPrevWindow::DrawParagraph(vcl::RenderContext& rRenderContext)
if (3 <= i && 6 > i)
{
long nLeft = nLeftMargin * aLineSiz.Width() / aSize.Width();
- long nFirst = nFirstLineOfst * aLineSiz.Width() / aSize.Width();
- long nTmp = nLeft + nFirst;
-
- if (i == 3)
- {
- aPnt.AdjustX(nTmp );
- aSiz.AdjustWidth( -nTmp );
- }
- else
- {
- aPnt.AdjustX(nLeft );
- aSiz.AdjustWidth( -nLeft );
- }
+ aPnt.AdjustX(nLeft );
+ aSiz.AdjustWidth( -nLeft );
long nRight = nRightMargin * aLineSiz.Width() / aSize.Width();
aSiz.AdjustWidth( -nRight );
}
- if (4 == i || 5 == i || 6 == i)
- {
- switch (eLine)
- {
- case SvxPrevLineSpace::N1:
- break;
- case SvxPrevLineSpace::N115:
- aPnt.AdjustY(nH / 6.67 ); // 1/.15 = 6.(6)
- break;
- case SvxPrevLineSpace::N15:
- aPnt.AdjustY(nH / 2 );
- break;
- case SvxPrevLineSpace::N2:
- aPnt.AdjustY(nH );
- break;
- case SvxPrevLineSpace::Prop:
- case SvxPrevLineSpace::Min:
- case SvxPrevLineSpace::Leading:
- break;
- }
- }
-
aPnt.AdjustY(nH );
if (3 <= i && 5 >= i)
@@ -385,12 +346,6 @@ void ParaPrevWindow::DrawParagraph(vcl::RenderContext& rRenderContext)
rRenderContext.DrawRect( aRect );
Lines[i] = aRect;
- if (5 == i)
- {
- auto nBottom = nLower * aLineSiz.Height() / aSize.Height();
- aPnt.AdjustY(nBottom * 2 );
- }
-
aPnt.AdjustY(nH );
// Reset, recalculate for each line
aPnt.setX( DEF_MARGIN / 2 );