@@ -270,8 +270,8 @@ RendererAgg::set_clipbox(const Py::Object& cliprect, R rasterizer) {
270270
271271 double l, b, r, t;
272272 if (py_convert_bbox (cliprect.ptr (), l, b, r, t)) {
273- rasterizer->clip_box (int (round (l)) + 1 , height - int (round (b)),
274- int (round (r)), height - int (round (t)));
273+ rasterizer->clip_box (int (mpl_round (l)) + 1 , height - int (mpl_round (b)),
274+ int (mpl_round (r)), height - int (mpl_round (t)));
275275 }
276276
277277 _VERBOSE (" RendererAgg::set_clipbox done" );
@@ -807,7 +807,7 @@ void RendererAgg::_draw_path(path_t& path, bool has_clippath,
807807 if (gc.linewidth != 0.0 ) {
808808 double linewidth = gc.linewidth ;
809809 if (!gc.isaa ) {
810- linewidth = (linewidth < 0.5 ) ? 0.5 : round (linewidth);
810+ linewidth = (linewidth < 0.5 ) ? 0.5 : mpl_round (linewidth);
811811 }
812812 if (gc.dashes .size () == 0 ) {
813813 stroke_t stroke (path);
@@ -1576,7 +1576,7 @@ RendererAgg::tostring_rgba_minimized(const Py::Tuple& args) {
15761576 int newwidth = 0 ;
15771577 int newheight = 0 ;
15781578 Py::String data;
1579- if (xmin < xmax and ymin < ymax) {
1579+ if (xmin < xmax && ymin < ymax) {
15801580 // Expand the bounds by 1 pixel on all sides
15811581 xmin = std::max (0 , xmin - 1 );
15821582 ymin = std::max (0 , ymin - 1 );
0 commit comments