Check out this dos library I made, it does quite a few different things, mouse, graphics, keyboard etc... I admit it has quite a few bugs and you might have some trouble getting it to compile but here it is:

stupid-mutt.50megs.com