Logo Search packages:      
Sourcecode: inkscape version File versions

double Geom::round ( double const   x  )  [inline]

Returns x rounded to the nearest integer. It is unspecified what happens if x is half way between two integers: we may in future use rint/round on platforms that have them.

Definition at line 63 of file utils.h.

Referenced by constrain_angle(), decimal_round(), and sp_canvas_scroll_to().

{ return std::floor(x + .5); }

Generated by  Doxygen 1.6.0   Back to index