summaryrefslogtreecommitdiff
path: root/sw/source
diff options
context:
space:
mode:
authorAndreas Martens <ama@openoffice.org>2002-01-23 14:19:14 +0000
committerAndreas Martens <ama@openoffice.org>2002-01-23 14:19:14 +0000
commitd195b93b50b5d5ee01b86e8eff126b33f7dbe740 (patch)
tree3f24f17a694241beb5c9d098931c03b6ada5fa0e /sw/source
parentbf0f1fb5dfa0fe6f48f763d8275ae95efcda3604 (diff)
New #96678#: Vertical grid
Diffstat (limited to 'sw/source')
-rw-r--r--sw/source/core/layout/paintfrm.cxx15
1 files changed, 8 insertions, 7 deletions
diff --git a/sw/source/core/layout/paintfrm.cxx b/sw/source/core/layout/paintfrm.cxx
index eb73e0a8b921..1571d8e21c0b 100644
--- a/sw/source/core/layout/paintfrm.cxx
+++ b/sw/source/core/layout/paintfrm.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: paintfrm.cxx,v $
*
- * $Revision: 1.18 $
+ * $Revision: 1.19 $
*
- * last change: $Author: ama $ $Date: 2002-01-23 13:51:59 $
+ * last change: $Author: ama $ $Date: 2002-01-23 15:19:14 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -3030,7 +3030,7 @@ void SwPageFrm::PaintGrid( OutputDevice* pOut, SwRect &rRect ) const
SwTwips nBottom = aInter.Top() + aInter.Height();
if( IsVertical() )
{
- SwTwips nOrig = aGrid.Left() + aGrid.Width() + aAdd[1];
+ SwTwips nOrig = aGrid.Left() + aGrid.Width() + aAdd[2];
SwTwips nY = nOrig + nRegSum *
( ( nOrig - aInter.Left() ) / nRegSum );
SwRect aTmp( Point( nY + aAdd[2], aInter.Top() ),
@@ -3047,7 +3047,7 @@ void SwPageFrm::PaintGrid( OutputDevice* pOut, SwRect &rRect ) const
{
nIdx = 3;
SwTwips nPosY = Max( aInter.Left(), nY );
- SwTwips nHeight = Min(nRight, aTmp.Pos().Y())-nPosY;
+ SwTwips nHeight = Min(nRight, aTmp.Pos().X())-nPosY;
if( nHeight > 0 )
{
SwRect aVert( Point( nPosY, nX ),
@@ -3068,11 +3068,12 @@ void SwPageFrm::PaintGrid( OutputDevice* pOut, SwRect &rRect ) const
if( !nIdx )
{
nIdx = 3;
- SwTwips nHeight = Min(nRight, aTmp.Pos().Y()) - nY;
+ SwTwips nHeight = aTmp.Pos().X()
+ - Max(aInter.Left(), nY );
if( nHeight > 0 )
{
- SwRect aVert( Point( nY, nX ),
- Size( nHeight, 1 ) );
+ SwRect aVert( Point( aTmp.Pos().X() - nHeight,
+ nX ), Size( nHeight, 1 ) );
while( aVert.Top() < nBottom )
{
pOut->DrawRect( aVert.SVRect() );