X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fcircle.cpp;h=75e9d9352e2749ccea3defaca75452bddb8d5aa9;hb=428876081ee41d40e32f5b4f2bfcfdb7a835e6e1;hp=909d30416bac3676beaf8d6d8cbe905184f04eb7;hpb=eb711912d64f17cf9c18c74c4d78d9867bd066ad;p=architektonas diff --git a/src/circle.cpp b/src/circle.cpp index 909d304..75e9d93 100644 --- a/src/circle.cpp +++ b/src/circle.cpp @@ -59,7 +59,7 @@ Circle::~Circle() { QString text = QObject::tr("Radius: %1\nScale: %2%"); text = text.arg(radius, 0, 'd', 4).arg(radius / oldRadius * 100.0, 0, 'd', 0); - +#if 0 QPen pen = QPen(QColor(0x00, 0xFF, 0x00), 1.0, Qt::SolidLine); painter->SetPen(pen); painter->SetBrush(QBrush(QColor(0x40, 0xFF, 0x40, 0x9F))); @@ -71,6 +71,9 @@ Circle::~Circle() pen = QPen(QColor(0x00, 0x5F, 0xDF)); painter->SetPen(pen); painter->DrawText(textRect, Qt::AlignVCenter, text); +#else + painter->DrawInformativeText(text); +#endif } } @@ -87,6 +90,11 @@ Circle::~Circle() objectWasDragged = false; HitTest(point); + // Now that we've done our hit testing on the non-snapped point, snap it if + // necessary... + if (snapToGrid) + point = SnapPointToGrid(point); + draggingCenter = hitCenter; draggingEdge = hitCircle;