Bug in xcolour.c
Brought to you by:
emmerson
Following my tentative to use xgks (see previous
bug report) I have found a second bug in it .
The source file concerned is lib/c/x/xcolour.c
on lines 523 and 525 there are calls to XcMap_enter
with ws->XcMap as first argument . This is wrong
because this routine needs a pointer to a map
as can be seen line 227 .
So I suggest to put &ws->XcMap in the calls (line
523 & 525) instead of ws->XcMap .
The other call line 593 seems to be correct .
------------------------------------------------------
Alain.Soyer@lmcp.jussieu.fr
Laboratoire de Mineralogie Cristallographie - Case 115
Universite P. et M.Curie et Paris 7 - CNRS UMR 7590
4, place Jussieu - 75252 Paris CEDEX 05 - FRANCE
Logged In: NO
To solve the problemas en xcolours.c do the following:
In XcMap_enter(map, index, pixel) function
// assert(pixel < map->length);
assert(index >= 0 && index < map->length);
// map->GKSindexes[pixel] = index;
map->GKSindexes[index] = index;
In XcInit(ws) function
XcMap_enter(
// ws->XcMap,
GKS_BACKGROUND_INDEX, BlackPixel(dpy, screenNum));
&(ws->XcMap),
GKS_BACKGROUND_INDEX, BlackPixel(dpy, screenNum));
XcMap_enter(
// ws->XcMap,
GKS_FOREGROUND_INDEX, WhitePixel(dpy, screenNum));
&(ws->XcMap),
GKS_FOREGROUND_INDEX, WhitePixel(dpy, screenNum));
Enrique Martinez HP Colombia
enrique.martinez@cmccol.com.co
kbeltda@hotmail.com