r16510 by craig - #9728: Fix crash when drawing a circle
scribus-commit
scribus-commit at lists.scribus.net
Fri Mar 25 23:57:04 CET 2011
Author: craig
Date: Fri Mar 25 22:57:04 2011
New Revision: 16510
URL: http://scribus.info/websvn/listing.php?repname=Scribus&sc=1&rev=16510
Log:
#9728: Fix crash when drawing a circle
Modified:
branches/Version135/Scribus/scribus/canvasmode_create.cpp
Modified: branches/Version135/Scribus/scribus/canvasmode_create.cpp
URL: http://scribus.info/websvn/diff.php?repname=Scribus&rev=16510&path=/branches/Version135/Scribus/scribus/canvasmode_create.cpp
==============================================================================
--- branches/Version135/Scribus/scribus/canvasmode_create.cpp (original)
+++ branches/Version135/Scribus/scribus/canvasmode_create.cpp Fri Mar 25 22:57:04 2011
@@ -80,9 +80,10 @@
if (createObjectMode != modeDrawLine)
{
- QRectF bounds = QRectF(topLeft, btRight).normalized();
- QRect localRect = m_canvas->canvasToLocal(bounds);
-
+ QRectF bounds = QRectF(topLeft, btRight).normalized();
+ QRect localRect = m_canvas->canvasToLocal(bounds);
+ if (localRect.width() <= 0 || localRect.height() <= 0)
+ return;
p->setRenderHint(QPainter::Antialiasing);
p->save();
More information about the scribus-commit
mailing list