wmii/libstuff/geom/rect_haspoint_p.c
2010-05-21 22:52:47 -04:00

11 lines
272 B
C

/* Copyright ©2006-2010 Kris Maglione <maglione.k at Gmail>
* See LICENSE file for license details.
*/
#include <stuff/geom.h>
bool
rect_haspoint_p(Point pt, Rectangle r) {
return (pt.x >= r.min.x) && (pt.x < r.max.x)
&& (pt.y >= r.min.y) && (pt.y < r.max.y);
}