home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 18 REXX / 18-REXX.zip / TJDMACS.ZIP / UNBOX.CMD < prev   
OS/2 REXX Batch file  |  1991-07-12  |  833b  |  37 lines

  1. /**/
  2.      parse arg row, col, width, depth, type, .
  3.      return Dounbox(row, col, width, depth, type);
  4.  
  5. Dounbox:    PROCEDURE
  6.      parse arg row, col, width, depth, type
  7.  
  8.      esc = d2c(27) || '[';
  9.  
  10.      hor = copies(' ', width - 2)
  11.      vert = ' ';
  12.  
  13.      stream = esc || 's';    /* Save cursor position */
  14.  
  15.      /* Position the cursor */
  16.      stream = stream || Goto(row, col);
  17.  
  18.      stream = stream || ' ' || hor || ' ';
  19.  
  20.      do depth
  21.     row = row + 1;
  22.     stream = stream || Goto(row, col);
  23.     stream = stream || vert;
  24.         stream = stream || Goto(row, col + width - 1);
  25.         stream = stream || vert;
  26.     end;
  27.  
  28.      row = row + 1;
  29.      stream = stream || Goto(row, col);
  30.  
  31.      stream = stream || ' ' || hor || ' ';
  32.  
  33.      stream = stream || esc || 'u';    /* Restore cursor position */
  34.      return stream
  35.  
  36.  
  37.