home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / Samples / CSAPE32.ARJ / SOURCE / OWLSCR / DIGCURSB.C < prev    next >
Encoding:
C/C++ Source or Header  |  1990-04-07  |  936 b   |  37 lines

  1. /*
  2.     digcursb.c
  3.  
  4.     % Function for getting graphics cursor box given cursor type.
  5.  
  6.     5/16/88  by Ted.
  7.     Extracted from pcfuncs.c
  8.  
  9.     OWL-DIG 1.2
  10.     Copyright (c) 1988, by Oakland Group, Inc.
  11.     ALL RIGHTS RESERVED.
  12.  
  13.     Revision History:
  14.     -----------------
  15.      3/28/90 jmd    ansi-fied
  16. */
  17.  
  18. #include "oakhead.h"
  19. #include "disppriv.h"
  20. #include "digutil.h"
  21.  
  22. /* -------------------------------------------------------------------------- */
  23.  
  24. void DIGPRIV dig_getcursbox(win_type win, cursortype ctype, opbox *cursboxp)
  25. {
  26.     opcoord start, end;
  27.  
  28.     dig_getcurslines(ctype, win_GetFontHeight(win), &start, &end);
  29.     cursboxp->xmin = win_GetCursx(win);
  30.     cursboxp->xmax = cursboxp->xmin + (win_GetFontWidth(win) * 7 / 8);
  31.     cursboxp->ymin = win_GetCursy(win) - win_GetFontHeight(win);
  32.     cursboxp->ymax = cursboxp->ymin + end;
  33.     cursboxp->ymin += start;
  34. }
  35. /* -------------------------------------------------------------------------- */
  36.  
  37.