[<<Previous Entry]
[^^Up^^]
[Next Entry>>]
[Menu]
[About The Guide]
SetGetColor()
Set or get the default GET colors.
------------------------------------------------------------------------------
Syntax:
SetGetColor( [<aNewGetColors>] ) --> <aGetColors>
OR
SetGetColor( <nColor> ) --> <cColor>
OR
SetGetColor( <cNewGetColors> ) --> <cFullColorStr>
OR
SetGetColor( <lWhen> ) --> <cPairColorStr>
Arguments:
<aNewGetColors> is an optional array containing the three color pairs
used by the GET system.
<aGetColors> is an array containing the current three color pairs used
by the GET system.
<nColor> is numeric expression from 1 to 3 representing the
corresponding current color pair of the GET system.
<cColor> is character string representing a requested color pair.
<cNewGetColors> is a character string containing the three color pairs
used by the GET system.
<cFullColorStr> is a character string containing the three color pairs
used by the GET system.
<lWhen> is a logical representing a passed or failed WHEN clause.
<cPairColorStr> is a character string containing two color pairs. The
first color pair represents the color when the GET is not in focus
and the second is when it is in focus. Depending on the value of
<lWhen> the first color pair will contain the color for an available
GET or an unavailable GET.
Description:
GETs require three colors: the color the GET is to be displayed in when
not infocus, the color it is to be dispalyed in when it is infocus and
the color it is to be displayed in when it is not infocus and the WHEN
clause has returned a FALSE. The GET object was originally designed to
use just 2 colors (infocus, not infocus). To get around this shortfall
SetGetColor() will except a logical (<lWhen>) which indicates whether
the GET's WHEN clause passed or failed. SetGetColor() will then return
a two color pair character string making up the appropriate colors.
Example:
The follow example will set the GET colors to bright white on black for
pending GETs, black on white (reverse) for the infocus GET, and grey on
black for nonaccessable (failed WHEN) GETs. In addition the old colors
are saved to be restored at the end of the module.
LOCAL aOldGetColor := SetGetColor( "W+/N,N/W,N+/N" )
.
.
.
SetGetColor( aOldGetColor )
Files: Library is CUACLIP.LIB.
See Also:
SetPopColor()
DEMO.PRG
This page created by ng2html v1.05, the Norton guide to HTML conversion utility.
Written by Dave Pearson