Module pos_misc

Module pos_misc 

Source
Expand description

Convenience utilities for testing whether a cursor/point falls inside a component or a rectangle. Functions operate using Px units and simple inclusive comparisons on edges.

Functionsยง

is_position_in_component
Returns true if position is inside a component of the given size. The component is assumed to be located at the origin (0, 0).
is_position_in_rect
Returns true when position lies within the rectangle defined by rect_pos, rect_width and rect_height (inclusive).