home *** CD-ROM | disk | FTP | other *** search
/ Programmer 7500 / MAX_PROGRAMMERS.iso / CLIPPER / MISC / EMXLIB8F.ZIP / EMX / LIB / VIDEO / VGETCTYP.C < prev    next >
Encoding:
C/C++ Source or Header  |  1993-01-02  |  597 b   |  31 lines

  1. /* vgetctyp.c (emx+gcc) -- Copyright (c) 1987-1993 by Eberhard Mattes */
  2.  
  3. #include <stdlib.h>
  4. #include <dos.h>
  5. #define INCL_VIO
  6. #include <os2emx.h>
  7. #include <sys/video.h>
  8. #include "video2.h"
  9.  
  10. void v_getctype (int *start, int *end)
  11. {
  12.   static VIOCURSORINFO cinfo;
  13.  
  14.   if (_osmode == OS2_MODE)
  15.     {
  16.       VioGetCurType (&cinfo, 0);
  17.       *start = cinfo.yStart -1;
  18.       *end = cinfo.cEnd -1;
  19.     }
  20.   else
  21.     {
  22.       union REGS r;
  23.  
  24.       r.h.ah = 0x03;
  25.       r.h.bh = 0x00;
  26.       _int86 (0x10, &r, &r);
  27.       *start = r.h.ch & 0x1f;
  28.       *end = r.h.cl & 0x1f;
  29.     }
  30. }
  31.