How to display coordinates for a polygon in in drawPolygon in QGraphicsView



  • How to display coordinates for a polygon in in drawPolygon in QGraphicsView


  • Qt Champions 2017

    Hi
    Do you do something like
    QPolygon poly;
    poly «QPoint(100,150) << QPoint(200,250);
    ...
    painter.drawPolygon(poly);

    if yes, you have the location of the points and can use drawText to show coordinates.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.