Hello Martin,
here a short collection of mouse-functions. I wrote them many years ago.
They alll use the MS-mouse-device-driver. They also works fine with Windows 9x ..
At first you have to init the mouse with mausstatus. You have to do
after you set the screen-mode.
If you have any further questions, you also can contact me directly ....
best regards Gerhard
sub mausstatus
shared maus
reg 1,&h00
call interrupt &h33
maus=reg(1)
end sub
sub mauspos(x,y,taste)
shared maus
if maus=0 then exit sub
reg 1,&h03
call interrupt &h33
x=reg(3)
y=reg(4)
taste=reg(2)
end sub
sub mauscuraus
shared maus
if maus=0 then exit sub
reg 1,&h02
call interrupt &h33
end sub
sub mauscurein
shared maus
if maus=0 then exit sub
reg 1,&h01
call interrupt &h33
end sub
sub setmauspos(x,y)
shared maus
if maus=0 then exit sub
reg 1,&h04
reg 3,x
reg 4,y
call interrupt &h33
end sub
sub mauswindowx(x1,x2)
shared maus
if maus=0 then exit sub
reg 1,&h07
reg 3,x1
reg 4,x2
call interrupt &h33
end sub
sub mauswindowy(y1,y2)
shared maus
if maus=0 then exit sub
reg 1,&h08
reg 3,y1
reg 4,y2
call interrupt &h33
end sub
sub mausrate(x,y)
shared maus
if maus=0 then exit sub
reg 1,&h0f
reg 3,x
reg 4,y
call interrupt &h33
end sub
------------------
Announcement
Collapse
No announcement yet.
mouse routines
Collapse
X
-
If you would like to roll your own, pick up a copy of PC Intern
by Michael Tischer. This a 1K+ page book that is a gold mine
if programming info.
------------------
Leave a comment:
-
Your first stop should be the Downloads area!
http://www.powerbasic.com/files/pub/pbdos/
File #1 in the PB/DOS Libraries section is 1STMOUSE.ZIP, which contains mouse
routines for FirstBasic. These should be perfectly compatible with PB/DOS 2.1.
You will probably find mouse support in many of the general-purpose libraries.
If the library is for PB/DOS 3.x, you might try contacting the author to see if
an older version is available. Some of the best authors may be found right here
in the PowerBASIC Forums!
------------------
Tom Hanlin
PowerBASIC Staff
Leave a comment:
-
mouse routines
Does anybody know of any Mouse routines/libraries for PB for Dos
v2.1 I've seen them for PB v3.0+, but those aren't real compati-
ble with v2.1.
------------------
Tags: None
Leave a comment: