Click to See Complete Forum and Search --> : Change system colors


christem
February 26th, 2003, 02:31 AM
Hi Everybody !!!

I'd like to change the system colors in Windows and I did it successfully with a Windows API function: SetSysColors, but this function changes system colors in whole Windows but I need system colors to be changed only in my application ! Is it possible.

Any ideas can be helpful.

Thanks Miki.

entr0py
July 4th, 2003, 12:27 AM
Most of the things you will ever need may be found @ the windows MSDN site or with your CD's if your a registered developer.

dwResult = GetSysColor(COLOR_BACKGROUND);
r = GetRValue(dwResult),
g = GetGValue(dwResult),
b = GetBValue(dwResult));


// Window elements to change.
int aiElements[3] = {COLOR_ACTIVEBORDER,
COLOR_ACTIVECAPTION,
COLOR_WINDOW};

// Array of RGB values.
DWORD aColors[3];

// Define the new colors.

aColors[0] = RGB(0x80, 0x00, 0x80); // dark purple
aColors[1] = RGB(0x00, 0x80, 0x80); // dark cyan
aColors[2] = RGB(0xC0, 0xC0, 0xC0); // light gray

// Set the window elements in aiElements to the colors
// specified in aColors.

SetSysColors(3, aiElements, aColors);


entr0py...




but now t

indiocolifa
July 5th, 2003, 06:52 PM
you may design your own interface using owner-drawn controls.