home *** CD-ROM | disk | FTP | other *** search
- /**
- *
- * Name scapage -- Display (activate) a video page
- *
- * Synopsis apage = scapage(page);
- *
- * int apage The video page actually displayed.
- * int page The page to display (activate).
- *
- * Description SCAPAGE sets the active display page, i.e., displays the
- * page. The cursor is not changed in form.
- *
- * Use SCPAGES to find how many pages are supported by the
- * current device in the current mode. Use SCPAGE to
- * direct C TOOLS PLUS screen output to a given page,
- * whether it is active (displayed) or not. Use SCACTPG to
- * display a page and to use its recorded cursor type.
- *
- * Returns apage The video page actually displayed.
- *
- * Version 3.0 (C)Copyright Blaise Computing Inc. 1983, 1984, 1986
- *
- **/
-
- #include <bscreen.h>
- #include <butility.h>
-
- int scapage(page)
- int page;
- {
- int ax,bx,cx,dx,flags; /* General registers */
- int max_page;
-
- max_page = scpages() - 1; /* Maximum page value */
-
- utbound(page,0,max_page)
-
- if (max_page) /* Switch active page only if */
- { /* this device supports more */
- ax = utbyword(5,page); /* than one. */
- bios(16,&ax,&bx,&cx,&dx,&flags);
- }
-
- return(page);
- }