🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.os.os2.programmer
Article #3178

Re: Is OS/2 really usable for programming?

#3178
From: Joe Barnhart
Date: Thu, 06 Jun 1991 22:26
37 lines
2300 bytes
In comp.os.os2.programmer, phil@ux1.cso.uiuc.edu (Phil Howard KA9WGN) writes:

  | I want my program to be able to trap and handle every keyboard state change
  | that takes place.  I want to handle both up and down keystrokes in any
  | combination.  Under MS-DOS I would just have my program take over the
  | interrupt handling of the keyboard directly.  How do I make a program do
  | this under OS/2?

Use a "keyboard monitor."  This is an OS-supplied "keyboard hook" which
allows you to do just about anything you want on keystrokes.  You can
hook a similar monitor on virtually any hardware device.

  | I want my program to be able to write directly to VGA buffers and registers
  | for the purpose of writing to the screen at the maximum possible speed, and
  | to be able to pan and scroll the screen smoothly at high speeds.  I also

Don't think for one second that OS/2 has the same limits on raw video 
performance that DOS does.  The standard "VIO" calls are _fast_ under OS/2.
You might find that you don't need to go to this trouble for video I/O 
speed.

  | want to be able to setup special modes such as 360x480x256 and others that
  | the VGA cards are actually capable of (not all the same for all cards, I do
  | know).  Under MS-DOS I can easily take control of the video card and do
  | just what I want.  How do I do this under OS/2?

This can be done, but only for a "full screen" application.  As you might
imagine, your customer wouldn't be very happy if you switched video modes
and his Presentation Manager screen went gaga (technical term).

For a good treatment on VIO calls, device monitors, etc., I recommend 
Ray Duncan's "Advanced OS/2 Programming" (or something like that).  Also,
Gordon Letwin's book on the philosophy of OS/2 is very enlightening.

-- Joe B.

#include <standard.disclaimer>
Technical Details
Message-ID: <11560004@hpnmdla.sr.hp.com>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!sdd.hp.com!hplabs!hpl-opus!hpnmdla!joeb
References: <1991Jun5.212129.11089@ux1.cso.uiuc.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!think.com!sdd.hp.com!hplabs!hpl-opus!hpnmdla!joeb
From: joeb@hpnmdla.sr.hp.com (Joe Barnhart)
Newsgroups: comp.os.os2.programmer
Subject: Re: Is OS/2 really usable for programming?
Message-ID: <11560004@hpnmdla.sr.hp.com>
Date: 6 Jun 91 22:26:37 GMT
References: <1991Jun5.212129.11089@ux1.cso.uiuc.edu>
Organization: HP Network Measurements Div, Santa Rosa, CA
Lines: 37