Logo Search packages:      
Sourcecode: qt4-x11 version File versions  Download package

void QPainterPath::moveTo ( const QPointF point  ) 

Moves the current point to the given point, implicitly starting a new subpath and closing the previous one.

See also:
closeSubpath(), {QPainterPath::Composing a QPainterPath}{Composing a QPainterPath}

Definition at line 596 of file qpainterpath.cpp.

References QPointF::x(), and QPointF::y().

Referenced by addEllipse(), addPolygon(), addRect(), arcMoveTo(), QPlastiqueStyle::drawComplexControl(), QPainter::drawLines(), QPainter::drawPie(), QRasterPaintEngine::drawPoints(), QPainter::drawPoints(), QCommonStyle::drawPrimitive(), QPicture::exec(), moveTo(), QGraphicsLineItem::shape(), QGraphicsEllipseItem::shape(), and toReversed().

#ifdef QPP_DEBUG
    printf("QPainterPath::moveTo() (%.2f,%.2f)\n", p.x(), p.y());
#ifndef QT_NO_DEBUG
    if (qt_is_nan(p.x()) || qt_is_nan(p.y()))
        qWarning("QPainterPath::moveTo: Adding point where x or y is NaN, results are undefined");

    QPainterPathData *d = d_func();

    d->require_moveTo = false;

    if (d->elements.last().type == MoveToElement) {
        d->elements.last().x = p.x();
        d->elements.last().y = p.y();
    } else {
        Element elm = { p.x(), p.y(), MoveToElement };
    d->cStart = d->elements.size() - 1;

Generated by  Doxygen 1.6.0   Back to index