X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fmirroraction.cpp;h=61b14ac1276be53c1199b3b310db421e0ff07834;hb=642cf72c11b49a9e00128ab6258a2438c785a5ab;hp=500f59d9e6cd89633c1571e85ee2fe8b0de21083;hpb=428876081ee41d40e32f5b4f2bfcfdb7a835e6e1;p=architektonas diff --git a/src/mirroraction.cpp b/src/mirroraction.cpp index 500f59d..61b14ac 100644 --- a/src/mirroraction.cpp +++ b/src/mirroraction.cpp @@ -13,6 +13,7 @@ #include "mirroraction.h" #include "line.h" +#include "mathconstants.h" #include "painter.h" //#include "vector.h" @@ -48,8 +49,13 @@ MirrorAction::~MirrorAction() painter->DrawLine(p1, p2); painter->DrawHandle(p2); - QString text = tr("Length: %1 in."); - text = text.arg(Vector::Magnitude(p1, p2)); + double absAngle = (Vector(p2 - p1).Angle()) * RADIANS_TO_DEGREES; +// double absLength = Vector(position - endpoint).Magnitude(); + + QString text = QChar(0x2221) + QObject::tr(": %1"); + text = text.arg(absAngle); +// QString text = tr("Length: %1 in."); +// text = text.arg(Vector::Magnitude(p1, p2)); painter->DrawInformativeText(text); } }