XPM icons malformed colour definition

This forum can be used to talk about general design strategies, new ideas and questions in general related to wxWidgets. If you feel your questions doesn't fit anywhere, put it here.
Post Reply
armink
Experienced Solver
Experienced Solver
Posts: 79
Joined: Tue Aug 31, 2004 10:25 am
Location: Bavaria / Germany

XPM icons malformed colour definition

Post by armink »

Hi again,

I try to embed an icon on win/cygwin and transformed the icon from .ico to .xpm, included the xpm, it compiles fine.

But when I start the app, errors like "maformed colour definition ..." appear.

I converted the ico with "GraphicsMagick" on X-Cygwin, tried to convert with CMYK, RGB ... always the same, only "monochrome" is accepted.

Has anybody a clue what the problem is with the colours ?

Example from the XPM file:

/* columns rows colors chars-per-pixel */
"32 32 64 1",
" c #0043BE00",
". c #0049C700",
"X c #0056D200",

etc ...
mjs
Experienced Solver
Experienced Solver
Posts: 93
Joined: Wed Feb 09, 2005 3:53 am
Contact:

Post by mjs »

Hi,

what is the color format of the hex values?
#0043BE00

Is it:
00 = R
43 = G
BE = B
00 = ??

or:
00 = ??
43 = R
BE = G
00 = B

The best would be that you use only 6-digit hex values ...

Regards,
Mark
armink
Experienced Solver
Experienced Solver
Posts: 79
Joined: Tue Aug 31, 2004 10:25 am
Location: Bavaria / Germany

xpm

Post by armink »

That was it !

Format was "RGB00", I just removed the trailing "00"s, now it works fine.

Thanx ! :)
Post Reply