On Wed, 11 Jun 2003, Chris Simmonds wrote: > Hi, > > I have a need to re-define "white" on an X server to be some other > colour. I feel sure that it is a simple thing to do, but I can't quite > see how. > > Here are some details > > Xfree86 4.2.1 running on Linux 2.4.18 kernel > vesa driver > LCD panel at 800x600x16 > > Although it is a full colour panel the application only displays white > text on a black background. I can't modify the application in any way, > just the configuration of the X server. > > Anybody got any ideas?
It depends how the app works. If it's asking for "white" by name you can change "white" globally in /usr/X11R6/lib/X11/rgb.txt If it asks for colors by specifying r,g,b values explicitly then you can change white by changing the gamma correction programatically through the xf86VidMode extension. See the XF86VidModeSetGammaRamp and XF86VidModeGetGammaRamp functions. Basically, get the gamma ramp out and change the last value in the red, green, and blue arrays to whatever you want white to be and set the modified gamma ramp. Mark. _______________________________________________ XFree86 mailing list [EMAIL PROTECTED] http://XFree86.Org/mailman/listinfo/xfree86