r15895 by jghali - #8548 mitigation patch : reduce page redraw problem when an object moved with arrow keys triggers a change in doc min coordinates
scribus-commit
scribus-commit at lists.scribus.net
Wed Nov 17 22:32:21 CET 2010
Author: jghali
Date: Wed Nov 17 21:32:21 2010
New Revision: 15895
URL: http://scribus.info/websvn/listing.php?repname=Scribus&sc=1&rev=15895
Log:
#8548 mitigation patch : reduce page redraw problem when an object moved with arrow keys triggers a change in doc min coordinates
Modified:
trunk/Scribus/scribus/canvas.cpp
trunk/Scribus/scribus/canvas.h
Modified: trunk/Scribus/scribus/canvas.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=15895&path=/trunk/Scribus/scribus/canvas.cpp
==============================================================================
--- trunk/Scribus/scribus/canvas.cpp (original)
+++ trunk/Scribus/scribus/canvas.cpp Wed Nov 17 21:32:21 2010
@@ -586,11 +586,11 @@
bool ret = false;
QRect viewport(-x(), -y(), m_view->viewport()->width(), m_view->viewport()->height());
// qDebug()<<"Canvas::adjustBuffer"<<viewport<<m_viewMode.forceRedraw<<m_viewMode.operItemSelecting;
- FPoint minCanvasCoordinate = m_doc->minCanvasCoordinate;
+ QPoint minCanvasCoordinate = canvasToLocal(QPointF(0.0, 0.0));
if (minCanvasCoordinate != m_oldMinCanvasCoordinate)
{
- m_bufferRect.translate(qRound((m_oldMinCanvasCoordinate.x() - minCanvasCoordinate.x())*m_viewMode.scale),
- qRound((m_oldMinCanvasCoordinate.y() - minCanvasCoordinate.y())*m_viewMode.scale));
+ m_bufferRect.translate(minCanvasCoordinate.x() - m_oldMinCanvasCoordinate.x(),
+ minCanvasCoordinate.y() - m_oldMinCanvasCoordinate.y());
m_oldMinCanvasCoordinate = minCanvasCoordinate;
}
#if DRAW_DEBUG_LINES
Modified: trunk/Scribus/scribus/canvas.h
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=15895&path=/trunk/Scribus/scribus/canvas.h
==============================================================================
--- trunk/Scribus/scribus/canvas.h (original)
+++ trunk/Scribus/scribus/canvas.h Wed Nov 17 21:32:21 2010
@@ -236,10 +236,10 @@
RenderMode m_renderMode;
/*QImage*/QPixmap m_buffer;
- QRect m_bufferRect;
+ QRect m_bufferRect;
QPixmap m_selectionBuffer;
- QRect m_selectionRect;
- FPoint m_oldMinCanvasCoordinate;
+ QRect m_selectionRect;
+ QPoint m_oldMinCanvasCoordinate;
};
More information about the scribus-commit
mailing list