Category : C Source Code
Archive   : CXLNGS51.ZIP
Filename : CXLTMOU.NMS
^bMouse Functions.^b
CXL has several functions used to facilitate Microsoft compatible mice.
All of these functions are prefixed with am 'ms'. These functions will
work on Microsoft mice or other mice using a Microsoft compatible
driver. These mouse functions allow you to:
^b1. Initialize mouse/determine if mouse exists.^b
^b2. Get the status of button presses/releases.^b
^b3. Hide/reveal the mouse cursor.^b
^b4. Get/set the mouse cursor position.^b
^b5. Select type of mouse cursor (hardware or software).^b
^b6. Adjust the mouse sensitivity (speed).^b
^b7. Get information on direction of mouse movement.^b
^b8. Establish horizontal/vertical boundaries of mouse movement.^b
The mscursor() function sets the cursor type. It takes 3 parameters:
ctype, smask, and cmask. If ctype = 1 then the cursor type is hardware.
The hardware cursor is the flashing block on your screen. If this type
of cursor is used, it will interfere with normal text cursor functions.
When using the hardware cursor type, the value for smask is the start
scan line of the cursor, and the value for cmask is the stop scan line
of the cursor. If the ctype parameter = 0, then a software cursor is
used. For the software cursor, the smask parameter is the screen mask,
and the cmask parameter is the cursor mask. The screen mask determines
which of the characters attributes are preserved. The cursor mask
defines how the attributes are changed to show the cursor. For both
masks, the bit values are as follows:
^bBits 0-7:^b ASCII value of character
^bBits 8-10:^b Foreground color
^bBit 11:^b Intensity
^bBits 12-14:^b Background color
^bBit 15:^b Blink
The msmotion() function determines direction and distance traveled since
last msmotion() call. The xcount and ycount parameters will either be
negative or positive depending on direction mouse moved. The amount
will be the number of rows/columns travelled.
When updating the screen, the mouse cursor should be hidden with the
mshidecur() function first, and then after the screen is updated, the
msshowcur() should be called to re-display the mouse cursor.
Very nice! Thank you for this wonderful archive. I wonder why I found it only now. Long live the BBS file archives!
This is so awesome! 😀 I’d be cool if you could download an entire archive of this at once, though.
But one thing that puzzles me is the “mtswslnkmcjklsdlsbdmMICROSOFT” string. There is an article about it here. It is definitely worth a read: http://www.os2museum.com/wp/mtswslnk/