##- # Author: Brian Tiffin # Dedicated to the public domain # # Date: November 2016 # Modified: 2016-11-25/17:12-0500 ##+ # # QueryPointer.icn, generate x,y position of mouse cursor # procedure main() w := open("main", "g", "size=150,50", "canvas=hidden") writes("mouse cursor relative to window w: ") pos := "" every pos ||:= QueryPointer(w) || "," write(pos[1:-1]) writes("mouse cursor relative to screen: ") pos := "" every pos ||:= QueryPointer() || "," write(pos[1:-1]) close(w) end