Skip to content

Commit

Permalink
round coordinates
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5176 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
rblazek committed Apr 5, 2006
1 parent 9c03a12 commit 30d4b24
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/plugins/grass/qgsgrassedit.cpp
Expand Up @@ -1519,8 +1519,8 @@ void QgsGrassEdit::displayElement ( int line, const QPen & pen, int size, QPaint
point.setX(mPoints->x[i]);
point.setY(mPoints->y[i]);
mTransform->transform(&point);
pointArray.setPoint( i, static_cast<int>(point.x()),
static_cast<int>(point.y()) );
pointArray.setPoint( i, static_cast<int>(round(point.x())),
static_cast<int>(round(point.y())) );
}

myPainter->setPen ( pen );
Expand Down Expand Up @@ -1634,8 +1634,8 @@ void QgsGrassEdit::displayIcon ( double x, double y, const QPen & pen,
point.setY(y);
mTransform->transform(&point);

int px = static_cast<int>(point.x());
int py = static_cast<int>(point.y());
int px = static_cast<int>(round(point.x()));
int py = static_cast<int>(round(point.y()));
int m = (size-1)/2;

QPainter *myPainter;
Expand Down

0 comments on commit 30d4b24

Please sign in to comment.