I lifted below test program out of a large code to get a handle on clearwin which was not behaving well when I compiled my code 64 bit (it basically showed a black rectangle obscuring the black text)

When I compile below test code win 32 it shows a black rectangle if I use the
the original draw_filled_rectangle statements and a green rectangle if I use the tweaked version (guessed the tweaked number).

I have 2 questions

1- Why is the original part of the code (thats works within the larger program) not working, and

2- Could someone perhaps point me to the section of the Clearwin manual that explains the coloring for draw rectangle

For a very long time, CW+ had the original 16 colour VGA setup as its default. Some versions ago, Paul realised that the world had moved on, and changed the default to the RGB mode where you can set all colours to have R, G and B components in the range 0..255 inclusive.

The routine SET_RGB_COLOURS_DEFAULT@ with a parameter 0 is used to select the VGA 16 colour mode, and with parameter 1 to select RGB colour mode. Then, you use a different method for VGA or RGB colour modes. The VGA mode is utter rubbish, and modern software should use RGB mode. You get the colour number with the routine RGB@.

... a table which begs the wuestion 'why is green not green, but 'lime' ?'_________________''Computers (HAL and MARVIN excepted) are incredibly rigid. They question nothing. Especially input data.Human beings are incredibly trusting of computers and don't check input data. Together cocking up even the simplest calculation ... "

My legacy code works firn under 32 bit with the VGA 16 color schema, but does not work with 64 bit.

so if this is the case doesn't this mean the defaut isn't the same for 32bit and 64bit ? and that default for 32bit is still VGA ?_________________''Computers (HAL and MARVIN excepted) are incredibly rigid. They question nothing. Especially input data.Human beings are incredibly trusting of computers and don't check input data. Together cocking up even the simplest calculation ... "