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

  1. /* wmdellin.c (emx+gcc) -- Copyright (c) 1987-1993 by Eberhard Mattes */
  2.  
  3. #include <string.h>
  4. #include <sys/winmgr.h>
  5. #include "winmgr2.h"
  6.  
  7. void wm_del_line (wm_handle wh, int y, int count)
  8. {
  9.   int i;
  10.   char *p1, *p2;
  11.  
  12.   if (wh->used != WM_USED || count <= 0)
  13.     return;
  14.   if (count > wh->height)
  15.     count = wh->height;
  16.   for (i = y; i < wh->height-count; ++i)
  17.     {
  18.       p1 = &DATA (wh, wh->ax, i+wh->ay);
  19.       p2 = p1 + 2 * count * wh->bwidth;
  20.       memmove (p1, p2, 2 * wh->width);
  21.     }
  22.   for (i = wh->height-count; i < wh->height; ++i)
  23.     _wm_clrline1 (wh, i+wh->ay, wh->ax,
  24.                   wh->width-1+wh->ax);
  25.   if (wh->display)
  26.     _wm_put1 (wh);
  27.   else
  28.     wh->update_req = TRUE;
  29.   _wm_cursor1 ();
  30.  
  31.