Hi,
there are the 24 standard colors in WinDev, these correspond to integer values describing the color. Putting the colors for selection as background-color into a combo (use: gBackground) is easy, the problem is readability of the forground text. e.g. black text on black background - no good.
In order to get readable rows in the combo I just inverted the text-colors in gPen(..) like here
FOR i = 1 TO 24
ListAdd(MySelf,gBackground(StdColor)+gPen(16777215 - StdColor)+StdColorName+gLink(StdColor))
END
For most colors more or less it does work, but it definitely doesn't work with DarkGray - because this color is mirroring axis for color inversion.
Question: is there a simple formula which makes the text readable in each and every case of the background color??
Kind regards,
Guenter