home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 7 / 07.iso / c / c005 / 4.ddi / C / SCPAGE.C < prev    next >
Encoding:
C/C++ Source or Header  |  1986-08-05  |  1.2 KB  |  44 lines

  1. /**
  2. *
  3. * Name        scpage -- Set the current display page
  4. *
  5. * Synopsis    cur_page = scpage(page);
  6. *
  7. *        int cur_page      The current display page actually set
  8. *        int page      The display page number to set as the
  9. *                  current page.
  10. *
  11. * Description    This function sets the global variable b_curpage to the
  12. *        current display page.  b_curpage is declared in
  13. *        BSCREEN.H and specifies the display page to be used by C
  14. *        TOOLS PLUS screen functions.  This page need not be
  15. *        active, i.e., currently displayed.
  16. *
  17. *        The current mode and device are checked so that an
  18. *        illegal page is not set.
  19. *
  20. *        Use SCACTPG or SCAPAGE to display any given page.  Use
  21. *        SCNEWDEV and SCCHGDEV to direct C TOOLS PLUS screen
  22. *        output to a given device.
  23. *
  24. * Returns    cur_page      The current page upon exit
  25. *        b_curpage  (global variable declared in BSCREEN.H)
  26. *                  The current page upon exit
  27. *
  28. * Version    3.0 (C)Copyright Blaise Computing Inc.    1983, 1984, 1986
  29. *
  30. **/
  31.  
  32. #include <bscreen.h>
  33.  
  34. int b_curpage = 0;              /* Initially set to zero          */
  35.  
  36. int scpage(page)
  37. int page;
  38. {
  39.     b_curpage = page;
  40.     utbound(b_curpage,0,scpages() - 1)
  41.  
  42.     return(b_curpage);
  43. }
  44.