home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 9 / 09.iso / l / l210 / 1.ddi / REFEXAMP.ARC / SCRATCHR.PRO < prev    next >
Encoding:
Text File  |  1988-06-21  |  776 b   |  18 lines

  1. %=====================  scr_attr/3 + scr_char/3  ============================
  2. /* This program demonstrates the built-in predicates scr_attr and
  3.    scr_char. Note: The colors used in this sample program may not
  4.    be visible on a monochrome system. */
  5.  
  6. goal    makewindow(1, 12, 7, "", 0, 0, 10, 40),
  7.     scr_attr(0, 0, 139),  scr_char(0, 0, 'a'),
  8.     scr_attr(0, 1, 72),   scr_char(0, 1, 'B'),
  9.     scr_attr(0, 2, 24),   scr_char(0, 2, 'c'),
  10.     scr_attr(0, 3, 33),   scr_char(0, 3, 'D'),
  11.     scr_attr(0, 4, 42),   scr_char(0, 4, 'e'),
  12.     scr_attr(0, 5, 94),   scr_char(0, 5, 'F'),
  13.     % Now read content of position (0,3)
  14.     scr_attr(0, 3, Attr),   scr_char(0, 3, Char),
  15.     cursor(2,0),
  16.     write("The attribute at position (0,3) is ", Attr),
  17.     write("\nand the character is ", Char, ".").
  18.