Ubuntu – Gimp colours do not fill correctly

gimp

This is probably a very easy question, but I am stumped.

I am trying to edit a png. I select a colour with the "Select by color" tool, change the fill colour to red ff0000, or 255,0,0, but when I click the selection to fill, it looks brown.

Other colours also act this way: blue -> purple, yellow -> light brown, etc. White seems to fill correctly.

So, what am I doing wrong? I'm thinking it has to do with the file format or some underlying filter.

Best Answer

It sounds like the image you are editing is using a limited colour palette rather than full 24-bit RGB. GIMP is doing its best to do what you ask while using colours in the existing palette.

If you want to switch the image to full colour, select Image -> Mode -> RGB from the menus. You should then be able edit the image using any colours you want.

If you need to save the image with an indexed colour palette, you can switch back again by picking the Indexed... menu item from the same menu. This will pop up a dialog box asking what sort of palette you want to use for the image. The default option should suffice.

If you don't need an indexed colour palette, I would just leave the image as RGB. For many of the images people use PNG files for, the savings are small.