Q3CanvasRectangle *decoratePoint(const QPoint& p) { const int SIZE = 4; UMLView *currentView = UMLApp::app()->currentView(); Q3CanvasRectangle *rect; rect = new Q3CanvasRectangle(p.x() - SIZE / 2, p.y() - SIZE / 2, SIZE, SIZE, currentView->canvas()); rect->setBrush( QBrush(Qt::blue) ); rect->setPen( QPen(Qt::blue) ); rect->setVisible(true); return rect; }