[prev in list] [next in list] [prev in thread] [next in thread]
List: koffice-devel
Subject: Re: [PATCH] Fix for kpresenter bug #63032
From: Thorsten Zachmann <t.zachmann () zagge ! de>
Date: 2003-10-08 4:19:47
[Download RAW message or body]
Hello
> > This patch should fix kpresenter bug 63032: When resizing a frame it does
> > not snap to the grid
> >
> > Ok to commit?
>
> Yes, thanks a lot for the patch.
Sorry, I didn't have time to test the patch earlier. There are some problems
with the patch.
Resizing up, left and all combinations with left and up do not work
correctly. This is only a copy and paste problem (wrong + -) and can easily
be fixed (patch is attached).
But if they are fixed there are still some problems. When resizing close to
the boarder of the page there is a flickering of the old and the new contour
of the object. Resizing up,left or down,right at the boarder is also not
working as expected (filckering of object between object resized up , object
resized left when resizing up left).
I do not know how to fix this.
I think there are two possibilities to solve this problem as the new behavior
is not realy much better than the old one.
1. fix remaining problems (no idea at the moment how it could be done)
2. revert the patch
What do you thing should be done.
Thorsten
["patch49" (text/x-diff)]
Index: kprcanvas.cc
===================================================================
RCS file: /home/kde/koffice/kpresenter/kprcanvas.cc,v
retrieving revision 1.373
diff -u -3 -p -r1.373 kprcanvas.cc
--- kprcanvas.cc 5 Oct 2003 18:19:29 -0000 1.373
+++ kprcanvas.cc 8 Oct 2003 04:15:58 -0000
@@ -5474,11 +5474,11 @@ void KPrCanvas::resizeObject( ModifyType
dy=0;
if ( keepRatio && ratio != 0.0 )
calcRatio( dx, dy, _modType, ratio );
- kpobject->setSize(m_origBRect.width() + dx, m_origBRect.height() + dy);
+ kpobject->setSize(m_origBRect.width() - dx, m_origBRect.height() - dy);
if ( objSize.width() != (kpobject->getSize()).width() )
- kpobject->setOrig(m_origBRect.x() - dx, kpobject->getOrig().y());
+ kpobject->setOrig(m_origBRect.x() + dx, kpobject->getOrig().y());
if ( objSize.height() != (kpobject->getSize()).height() )
- kpobject->setOrig(kpobject->getOrig().x(), m_origBRect.y() - dy);
+ kpobject->setOrig(kpobject->getOrig().x(), m_origBRect.y() + dy);
} break;
case MT_RESIZE_LF: {
dy = 0;
@@ -5486,9 +5486,9 @@ void KPrCanvas::resizeObject( ModifyType
dx=0;
if ( keepRatio && ratio != 0.0 )
calcRatio( dx, dy, _modType, ratio );
- kpobject->setSize(m_origBRect.width() + dx, m_origBRect.height() + dy);
+ kpobject->setSize(m_origBRect.width() - dx, m_origBRect.height() - dy);
if ( objSize != kpobject->getSize() )
- kpobject->setOrig(m_origBRect.x() - dx, kpobject->getOrig().y());
+ kpobject->setOrig(m_origBRect.x() + dx, kpobject->getOrig().y());
} break;
case MT_RESIZE_LD: {
if( (point.y()+objRect.height()+dy) > pageRect.height())
@@ -5497,9 +5497,9 @@ void KPrCanvas::resizeObject( ModifyType
dx=0;
if ( keepRatio && ratio != 0.0 )
calcRatio( dx, dy, _modType, ratio );
- kpobject->setSize(m_origBRect.width() + dx, m_origBRect.height() + dy);
+ kpobject->setSize(m_origBRect.width() - dx, m_origBRect.height() + dy);
if ( objSize.width() != (kpobject->getSize()).width() )
- kpobject->setOrig(m_origBRect.x() - dx, kpobject->getOrig().y());
+ kpobject->setOrig(m_origBRect.x() + dx, kpobject->getOrig().y());
} break;
case MT_RESIZE_RU: {
if( (point.x()+objRect.width()+dx) > pageRect.width())
@@ -5508,9 +5508,9 @@ void KPrCanvas::resizeObject( ModifyType
dy=0;
if ( keepRatio && ratio != 0.0 )
calcRatio( dx, dy, _modType, ratio );
- kpobject->setSize(m_origBRect.width() + dx, m_origBRect.height() + dy);
+ kpobject->setSize(m_origBRect.width() + dx, m_origBRect.height() - dy);
if ( objSize.height() != (kpobject->getSize()).height() )
- kpobject->setOrig(kpobject->getOrig().x(), m_origBRect.y() - dy);
+ kpobject->setOrig(kpobject->getOrig().x(), m_origBRect.y() + dy);
} break;
case MT_RESIZE_RT: {
dy = 0;
@@ -5535,9 +5535,10 @@ void KPrCanvas::resizeObject( ModifyType
dy=0;
if ( keepRatio && ratio != 0.0 )
calcRatio( dx, dy, _modType, ratio );
- kpobject->setSize(m_origBRect.width() + dx, m_origBRect.height() + dy);
+ kpobject->setSize(m_origBRect.width() - dx, m_origBRect.height() - dy);
if ( objSize != kpobject->getSize() )
- kpobject->setOrig(kpobject->getOrig().x(), m_origBRect.y() - dy);
+ kpobject->setOrig(kpobject->getOrig().x(), m_origBRect.y() + dy);
+
} break;
case MT_RESIZE_DN: {
dx = 0;
_______________________________________________
koffice-devel mailing list
koffice-devel@mail.kde.org
http://mail.kde.org/mailman/listinfo/koffice-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic