612 } |
612 } |
613 } |
613 } |
614 } |
614 } |
615 elif (editMode() == CircleMode) |
615 elif (editMode() == CircleMode) |
616 { // If we have not specified the center point of the circle yet, preview it on the screen. |
616 { // If we have not specified the center point of the circle yet, preview it on the screen. |
617 if (m_drawedVerts.size() == 0) |
617 if (m_drawedVerts.isEmpty()) |
618 drawBlip (paint, coordconv3_2 (m_hoverpos)); |
618 drawBlip (paint, coordconv3_2 (m_hoverpos)); |
619 else |
619 else |
620 { QVector<vertex> verts, verts2; |
620 { QVector<vertex> verts, verts2; |
621 const double dist0 = circleDrawDist(0), |
621 const double dist0 = circleDrawDist (0), |
622 dist1 = (m_drawedVerts.size() >= 2) ? circleDrawDist (1) : -1; |
622 dist1 = (m_drawedVerts.size() >= 2) ? circleDrawDist (1) : -1; |
623 const int segs = lores; |
623 const int segs = lores; |
624 const double angleUnit = (2 * pi) / segs; |
624 const double angleUnit = (2 * pi) / segs; |
625 Axis relX, relY; |
625 Axis relX, relY; |
626 QVector<QPoint> ringpoints, circlepoints, circle2points; |
626 QVector<QPoint> ringpoints, circlepoints, circle2points; |
1819 // ----------------------------------------------------------------------------- |
1819 // ----------------------------------------------------------------------------- |
1820 void GLRenderer::updateRectVerts() |
1820 void GLRenderer::updateRectVerts() |
1821 { if (!m_rectdraw) |
1821 { if (!m_rectdraw) |
1822 return; |
1822 return; |
1823 |
1823 |
1824 if (m_drawedVerts.size() == 0) |
1824 if (m_drawedVerts.isEmpty()) |
1825 { for (int i = 0; i < 4; ++i) |
1825 { for (int i = 0; i < 4; ++i) |
1826 m_rectverts[i] = m_hoverpos; |
1826 m_rectverts[i] = m_hoverpos; |
1827 |
1827 |
1828 return; |
1828 return; |
1829 } |
1829 } |