|
|
|
|
|
- Gradient parameters
- Background color
gBackgroundGradient (Function) In french: gFondDégradé Describes a display color in gradient mode. This color can be used for the background of the text displayed in an element of a List Box or Combo Box control, for a table cell, etc. Warning This function cannot be used directly for a window background (see example below).
ListAdd(LISTE_ListeCouleur, gBackgroundGradient(LightRed, LightGreen) + "Jaune")
LIB_Elément.Libellé = gBackgroundGradient(RGB(166, 223, 98), RGB(87, 171, 47)) + gPen(LightRed) + ...
"Libellé avec fond dégradé"
MonImage is string
MonImage = CompleteDir(fExeDir()) + "ImageFond.JPG"
IF fFileExist(MonImage) = True THEN fDelete(MonImage)
IMG_Degrade = gBackgroundGradient(PastelRed, PastelBlue, 70)
dSaveImageJPEG(IMG_Degrade, MonImage, 65)
FEN_Fenêtre1.ImageFond = MonImage
Syntax
<Result> = gBackgroundGradient(<Start color> , <End color> [, <Angle> [, <Color 3> [, <Distance color 3> [, <Color 4> [, <Distance color 4>]]]]])
<Result>: Character string Control string to be used: <Start color>: Integer or constant Start color of the gradient. This color can correspond to: <End color>: Integer or constant End color of the gradient. This color can correspond to: <Angle>: Optional integer Angle that will be used for the selection of colors in the gradient. The angle value is included between 0 (horizontal angle, default value) and 360°. <Color 3>: Optional constant or integer Color that will be used in the gradient. This color can correspond to: <Distance color 3>: Optional integer Percentage separating the start color from color 3. <Color 4>: Optional constant or integer Color that will be used in the gradient. This color can correspond to: <Distance color 4>: Optional integer Percentage separating the start color from color 4. Remarks The color parameters are used as follows: The angle is used to define the orientation of the gradient. The gradients performed with 3 or 4 colors are only available for an angle set to 0 or 90 degrees. Note Gradients are not available on some systems or under TSE 256 colors. In this case, a rectangle whose color corresponds to <Start color> is displayed. - gBackgroundGradient can be used to define the background of a clickable area in the title bar and status bar of a window or in a Static Text control.
- When gBackgroundGradient is called with the Transparent constant, text can overlay an image.
This page is also available for…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|