Add examples/pointer2.py

A more sophisticated version of pointer.py using rectangles to control
the boundaries of the area in which the pointer is allowed to move.