[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 SETMAXROW()
 Sets the number of lines for a virtual screen
------------------------------------------------------------------------------
 Syntax

     SETMAXROW(<nLastLine>, [<nScrollBorder>])
        --> lSuccessful

 Arguments

     <nLastLine>  Designates the last line that the extended driver
     supports for screen output.  The highest value possible is 254, assuming
     sufficient screen memory is available.

     <nScrollBorder>  Designates the top and bottom borders that move the
     screen when crossed by the cursor.  Values from 0 to MAXCOL(.T.)/2 are
     valid.  Larger values are corrected to the maximum value.  When a value
     is passed for this parameter, scroll is turned on.   When no parameter
     is passed, scroll is turned off.

 Returns

     SETMAXROW() returns .T. when <nLastLine> is successfully set.

 Description

     This function allows you to set the number of lines that the extended
     driver accepts for CA-Clipper screen output.  You can determine two
     different types of screen output.

     Special Screen
     It is possible to use full page screens or other special screens that
     display more than 25 lines, and whose line count is not automatically
     recognized by the BIOS (this is always hardware based).  These screens
     must be compatible with the usual screen adapter with regard to the
     organization of the screen memory (character attributes), the attribute
     bytes themselves, and the basic address of the screen memory.  The
     function doesn't switch any modes; the internal settings of the extended
     drivers are simply adjusted.  Specific screen settings must be carried
     out through the hardware's driver module.

     Virtual Screen
     It is also possible to set a line count higher than what can be
     displayed on the screen.  In this case, only a portion of the total
     screen memory is visible.  If a CA-Clipper input command such as
     GET/READ is built larger than the visible area, the extended driver
     automatically moves screen memory in accordance with cursor movement.
     This movement always occurs when the cursor moves beyond the left or the
     right borders set in <nScrollBorder>.  In this way, the portion of text
     that is worked on is always visible.  The visible area of the virtual
     screen can also be set using the FIRSTROW() function if needed.

     Virtual screens are possible on CGA, EGA, and VGA adapters as well as
     those that can fully emulate them.  The maximum number of lines you can
     install, assuming a 25-line and 80-column mode (CGA80() or
     MONOCHROME()), can be determined in the following manner:

     MIN(INT((MAXPAGE() +1) * 2048 / 80), 254)

     With eight screen pages you have:

     MIN(INT(8 * 2048 / 80), 254)   204

     In other words, a maximum of 204 lines can be used, which exactly equals
     the maximum value for SETMAXROW() of 203.

     You can switch back to the number of lines that actually display by
     calling the function with the corresponding value and no border.

 Notes

     .  We are not able to provide any kind of technical support when
        unknown screen hardware is used.  Full page screens do exist on the
        market which fulfill the conditions described above.

     .  Please notice that virtual screens use the memory area for
        additional screen pages.  The number of screen pages decreases in
        proportion to the growth of the virtual screen.

     .  If the <nScrollBorder> is larger than or equal to half of the
        visible columns, then the display in the middle of the screen is
        scrolled under the cursor.

     .  If the cursor is switched off, the automatic scroll depends
        only on keyboard input.

     .  When windows are open, the line count cannot be changed,
        regardless of the automatic scroll setting.

 Examples

     .  Set the number of lines to 72 (full page screen):

        SETMAXROW(71)                 // 72 lines
        @ 65, 20 SAY "CA-Clipper"

     .  Switch a VGA adapter to a 100-line screen.  As soon as the
        cursor is in the region of the top or bottom tow lines, the screen
        moves:

        ? SETMAXROW(99, 2)            // Returns .T. if successful

     .  Switch off the automatic scroll:

        SETMAXROW(MAXROW(.T.))


See Also: SETMAXCOL() FIRSTROW()
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson