41 pt_in_rect(
const Gdk::Point &point,
const Gdk::Rectangle &rect)
43 return (point.get_x() >= rect.get_x() &&
44 point.get_x() < rect.get_x() + rect.get_width() &&
45 point.get_y() >= rect.get_y() &&
46 point.get_y() < rect.get_y() + rect.get_height());
53 max(a.get_x(), b.get_x()) <
54 min(a.get_x() + a.get_width(), b.get_x() + b.get_width())
56 max(a.get_y(), b.get_y()) <
57 min(a.get_y() + a.get_height(), b.get_y() + b.get_height())
bool rects_overlap(Gdk::Rectangle const &a, Gdk::Rectangle const &b)
determine whether two rectangles overlap
Helper functions to work with rectangular screen ranges.
bool pt_in_rect(const Gdk::Point &point, const Gdk::Rectangle &rect)
determine whether point is within the bounding box of a rectangle
Lumiera GTK UI implementation root.