SP Mice implementation

Mice and SuperLib

 SuperLib contains a set of mouse and event functions.
 These functions are MOSTLY prefaced with 'RAT' for uniqueness.

 The basic functions are written in assembler (MASM
 5.10) and are in s_mouse.asm. These provide such things as
 testing for a mouse, turning the mouse cursor on, turning it off,
 positioning it.

 Also provided are two approaches to knowing where the
 mouse is and what it is doing. The first is a direct query of
 the mouse's status and position. This is basically, "where is the
 mouse right now, is the right button depressed right now, is the
 left button depressed right now". These are accomplished through
 service 3 of interrupt 33h.

 The second approach is to use service 5 of interrupt
 33h, which 'records' right and left mouse button depresses and
 where the mouse was when these occurred.

 These Clipper functions, contained in s_moose.prg,
 are included to provide a simple event manager to trap both keys
 and mouse events and store them for reference.

 The event manager RAT_EVENT() can be used in place of
 inkey(), and will detect a keypress, a mouse left button press,
 a mouse right button press, or a timeout. The 'event' returns a
 value similiar to inkey(), but adds values of 400 and 500 for
 mouse right and left presses. Functions are provided to find out
 the mouse row and column when the event occurred.

 Two additional functions RAT_READ() and RAT_MENU2()
 are provided which use the mouse and event functions to perform
 a read and a menu to emulation. These are also good examples for
 usage of the mouse and event functions.

 All SuperLib functions are mouse aware, as of version 3.5.

 

One response to “SP Mice implementation

  1. Pingback: Superlib | Viva Clipper !

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.