Thanks for all the info Per, this is exactly what I was after. Do you know why d1.l is labeled x,y pointer coordinates on both input and output?
Cheers Malcolm P Witte wrote: > Wolfgang Lenerz writes: > >> On 22 Nov 2001, at 0:38, P Witte wrote: >> >> >>> Im not sure how much of the documentation ought to be reproduce >> > here > >>> as it probably is copywrited material. Any thoughts on that, >> > anyone? > >> No problem if you rephrase it. > > > Ah! Thats probably why it costs money ;) > > Its been a long time, so my comments are postfixed with a ? > > IOP.RPTR - Read pointer > > Trap#3 d0 = $71 > > input: d1.l x,y pointer coordinates > d2.b termination vector > d3.l timeout > a0 channel ID > a1 -> pointer record > > output : d1.l x,y pointer coordinates > d2+ preserved > a0 preserved (unless error?) > a1+ preserved > > error: NO channel not open > > > x,y coordinates relative to screen. > > > Termination vector: > > Setting one or more bits determines what will terminate the iop.rptr > call : > > bit 0 - key or button stroke in window / window resize > 1 - key or button pressed (reacts to auto repeat) > 2 - key or button up in window > 3 - pointer moved from given coordinates in window > 4 - pointer moved out of window > 5 - pointer in window > 6 - reserved (edge of screen?) > 7 - special window request > > Setting bits 4 and 5 will cause immediate termination even if the > window is locked. > Setting bit 7 is special: Timeout should be -1, and bits 2 to 6 > should be zeroed. The sprite shown depends on the setting of bits 0 > and 1: > bit 0 - move window > 1 - change size > none - empty window > both - no sprite shown? > > > The pointer record is somewhere to store $18 bytes of information > resulting from the call: > > 00 .l ID of window enclosing pointer > 04 .w sub-window enclosing pointer > (or -1 => outside window?) > 06 .w x-pixel coordinate of pointer within (sub-)window > 08 .w y-pixel coordinate of pointer within (sub-)window > 0a .b 0 => no keystroke; <> 0 => keycode > 0b .b 0 => no key down; <> 0 => space or button depressed > 0c .l event vector, all zero except the ls byte, which is > the termination vector > 10 .w x 4 containing (sub-)window definition: size xy and > origen xy. > > > As you see, theres a lot more. To describe the workings would be more > like an article than an email. > > You can also read the pointer through the window manager (wman) using > wm.rptr, vector $30. This vectored utility is the one to use if youre > using a window definition under wman, but if anyone figured out how to > do that without the manual they dont need my help ;) > > Sorry it took so long to reply. Ive been away. HTH anyway. > > Per > > > > > > > >
