2009-05-23

Colorful Epiphany

I always thought that the RGB macro (Win32 GDI) which takes three arguments - red, green and blue - will create a 0xRRGGBB value.

I was wrong! Win32 GDI uses BGR colors! d'oh

Here is another assertion on the path of assertiveness (germ. Durchsetzungsvermögen)

#include <windows.h>
#include <assert.h>

int main()
{
     COLORREF color_rgb = 0xBBAADD;
    
     assert(color_rgb == RGB(0xBB, 0xAA, 0xDD));
}

Cheers!

2009-05-12

Visual Studio 2008 Donation

I would like to thank Opera Software for the retail package of Visual Studio 2008 Standard Edition I just received!


Thank you!