home *** CD-ROM | disk | FTP | other *** search
- /**
- *
- * Name scrows -- Return the number of character rows on the
- * screen
- *
- * Synopsis rows = scrows();
- *
- * int rows Returned number of rows
- *
- * Description SCROWS returns the number of character rows on the
- * screen, taking into account the possible presence of an
- * Enhanced Graphics Adapter.
- *
- * Use SCMODE to find the number of text columns.
- *
- * Returns rows Number of rows
- *
- * Version 3.0 (C)Copyright Blaise Computing Inc. 1986
- *
- **/
-
- #include <bscreen.h>
-
- int scrows()
- {
- int ax,bx,cx,dx,flags; /* Registers for BIOS call */
-
- if (!b_know_hw)
- scequip(); /* Look for EGA */
- if (b_ega != ABSENT)
- {
- ax = 0x1130;
- bx = 0;
- bios(16,&ax,&bx,&cx,&dx,&flags);
- return utlobyte(dx) + 1;
- }
-
- return PC_ROWS;
- }