- char rbuf[3];
- DecToHex( (unsigned char)(key >> 16), rbuf );
- char gbuf[3];
- DecToHex( (unsigned char)(key >> 8), gbuf );
- char bbuf[3];
- DecToHex( (unsigned char)(key), bbuf );
- sprintf( tmpbuf, "\"%s c #%s%s%s\",\n", sym, rbuf, gbuf, bbuf );
+ wxByte r = wxByte(key >> 16);
+ wxByte g = wxByte(key >> 8);
+ wxByte b = wxByte(key);
+ sprintf(tmpbuf, "\"%s c #%02X%02X%02X\",\n", sym, r, g, b);