Commit 264d09b4 authored by Clayton Walker's avatar Clayton Walker

Rename colour and greyscale to color and grayscale respectively

parent c2da46d8
......@@ -373,7 +373,7 @@ gimp_brush_real_transform_mask (GimpBrush *brush,
*
* The algorithm used is exactly the same as for the brush mask
* (gimp_brush_real_transform_mask) except it accounts for 3 color channels
* instead of 1 greyscale channel.
* instead of 1 grayscale channel.
*
* Rather than calculating the inverse transform for each point in the
* transformed image, this algorithm uses the inverse transformed
......
......@@ -22,17 +22,17 @@
* worse or better depending on what you enjoy...). [adam@gimp.org]
*
* 2004-12-12 - Use a slower but much nicer technique for finding the
* two best colours to dither between when using fixed/positional
* two best colors to dither between when using fixed/positional
* dither methods. Makes positional dither much less lame. [adam@gimp.org]
*
* 2002-02-10 - Quantizer version 3.0 (the rest of the commit started
* a year ago -- whoops). Divide colours within CIE L*a*b* space using
* CPercep module (cpercep.[ch]), colour-match and dither likewise,
* a year ago -- whoops). Divide colors within CIE L*a*b* space using
* CPercep module (cpercep.[ch]), color-match and dither likewise,
* change the underlying box selection criteria and division point
* logic, bump luminance precision upwards, etc.etc. Generally
* chooses a much richer colour set, especially for low numbers of
* colours. n.b.: Less luminance-sloppy in straight remapping which is
* good for colour but a bit worse for high-frequency detail (that's
* chooses a much richer color set, especially for low numbers of
* colors. n.b.: Less luminance-sloppy in straight remapping which is
* good for color but a bit worse for high-frequency detail (that's
* partly what fs-dithering is for -- use it). [adam@gimp.org]
*
* 2001-03-25 - Define accessor function/macro for histogram reads and
......@@ -40,7 +40,7 @@
* dirty tricks we used when we knew that the histogram was a straight
* 3d array, so I've recovered some of the speed loss by implementing
* a 5d accessor function with good locality of reference. This change
* is the first step towards quantizing in a more interesting colourspace
* is the first step towards quantizing in a more interesting colorspace
* than frumpy old RGB. [Adam]
*
* 2000/01/30 - Use palette_selector instead of option_menu for custom
......@@ -48,14 +48,14 @@
*
* 99/09/01 - Created a low-bleed FS-dither option. [Adam]
*
* 99/08/29 - Deterministic colour dithering to arbitrary palettes.
* 99/08/29 - Deterministic color dithering to arbitrary palettes.
* Ideal for animations that are going to be delta-optimized or simply
* don't want to look 'busy' in static areas. Also a bunch of bugfixes
* and tweaks. [Adam]
*
* 99/08/28 - Deterministic alpha dithering over layers, reduced bleeding
* of transparent values into opaque values, added optional stage to
* remove duplicate or unused colour entries from final colourmap. [Adam]
* remove duplicate or unused color entries from final colormap. [Adam]
*
* 99/02/24 - Many revisions to the box-cut quantizer used in RGB->INDEXED
* conversion. Box to be cut is chosen on the basis of possessing an axis
......@@ -71,7 +71,7 @@
* 98/07/25 - Convert-to-indexed now remembers the last invocation's
* settings. Also, GRAY->INDEXED is more flexible. [Adam]
*
* 98/07/05 - Sucked the warning about quantizing to too many colours into
* 98/07/05 - Sucked the warning about quantizing to too many colors into
* a text widget embedded in the dialog, improved intelligence of dialog
* to default 'custom palette' selection to 'Web' if available, and
* in this case not bother to present the native WWW-palette radio
......@@ -86,10 +86,10 @@
* 97/11/14 - added a proper pdb interface and support for dithering
* to custom palettes (based on a patch by Eric Hernes) [Yosh]
*
* 97/11/04 - fixed the accidental use of the colour-counting case
* 97/11/04 - fixed the accidental use of the color-counting case
* when palette_type is WEB or MONO. [Adam]
*
* 97/10/25 - colour-counting implemented (could use some hashing, but
* 97/10/25 - color-counting implemented (could use some hashing, but
* performance actually seems okay) - now RGB->INDEXED conversion isn't
* destructive if it doesn't have to be. [Adam]
*
......@@ -848,9 +848,9 @@ gimp_image_convert_type (GimpImage *image,
else
zero_histogram_rgb (quantobj->histogram);
/* To begin, assume that there are fewer colours in
/* To begin, assume that there are fewer colors in
* the image than the user actually asked for. In that
* case, we don't need to quantize or colour-dither.
* case, we don't need to quantize or color-dither.
*/
needs_quantize = FALSE;
num_found_cols = 0;
......@@ -871,7 +871,7 @@ gimp_image_convert_type (GimpImage *image,
progress, nth_layer, n_layers);
/* Note: generate_histogram_rgb may set needs_quantize if
* the image contains more colours than the limit specified
* the image contains more colors than the limit specified
* by the user.
*/
}
......@@ -886,7 +886,7 @@ gimp_image_convert_type (GimpImage *image,
palette_type == GIMP_MAKE_PALETTE)
{
/* If this is an RGB image, and the user wanted a custom-built
* generated palette, and this image has no more colours than
* generated palette, and this image has no more colors than
* the user asked for, we don't need the first pass (quantization).
*
* There's also no point in dithering, since there's no error to
......@@ -1333,26 +1333,26 @@ generate_histogram_rgb (CFHistogram histogram,
goto already_found;
}
/* Colour was not in the table of
* existing colours
/* Color was not in the table of
* existing colors
*/
num_found_cols++;
if (num_found_cols > col_limit)
{
/* There are more colours in the image
/* There are more colors in the image
* than were allowed. We switch to plain
* histogram calculation with a view to
* quantizing at a later stage.
*/
needs_quantize = TRUE;
/* g_print ("\nmax colours exceeded - needs quantize.\n");*/
/* g_print ("\nmax colors exceeded - needs quantize.\n");*/
goto already_found;
}
else
{
/* Remember the new colour we just found.
/* Remember the new color we just found.
*/
found_cols[num_found_cols-1][0] = data[RED];
found_cols[num_found_cols-1][1] = data[GREEN];
......@@ -1399,14 +1399,14 @@ find_split_candidate (const boxptr boxlist,
*which_axis = AXIS_UNDEF;
/* we only perform the initial L-split bias /at all/ if the final
number of desired colours is quite low, otherwise it all comes
number of desired colors is quite low, otherwise it all comes
out in the wash anyway and this initial bias generally only hurts
us in the long run. */
if (desired_colors <= 16)
{
#define BIAS_FACTOR 2.66F
#define BIAS_NUMBER 2 /* 0 */
/* we bias towards splitting across L* for first few colours */
/* we bias towards splitting across L* for first few colors */
Lbias = (numboxes > BIAS_NUMBER) ? 1.0F : ((double)(BIAS_NUMBER+1) -
((double)numboxes)) /
((double)BIAS_NUMBER / BIAS_FACTOR);
......@@ -2113,7 +2113,7 @@ compute_color_gray (QuantizeObj *quantobj,
}
else /* The only situation where total==0 is if the image was null or
* all-transparent. In that case we just put a dummy value in
* the colourmap.
* the colormap.
*/
{
quantobj->cmap[icolor].red =
......@@ -2180,7 +2180,7 @@ compute_color_rgb (QuantizeObj *quantobj,
}
else /* The only situation where total==0 is if the image was null or
* all-transparent. In that case we just put a dummy value in
* the colourmap.
* the colormap.
*/
{
quantobj->cmap[icolor].red = 0;
......@@ -2237,7 +2237,7 @@ compute_color_lin8 (QuantizeObj *quantobj,
}
else /* The only situation where total==0 is if the image was null or
* all-transparent. In that case we just put a dummy value in
* the colourmap.
* the colormap.
*/
{
g_warning("eep.");
......@@ -3019,16 +3019,16 @@ median_cut_pass2_fixed_dither_gray (QuantizeObj *quantobj,
}
else
{
/* not enough colours to bother looking for an 'alternative'
colour (we may fail to do so anyway), so decide that
the alternative colour is simply the other cmap entry. */
/* not enough colors to bother looking for an 'alternative'
color (we may fail to do so anyway), so decide that
the alternative color is simply the other cmap entry. */
pixval2 = (pixval1 + 1) %
(quantobj->actual_number_of_colors);
}
/* always deterministically sort pixval1 and pixval2, to
avoid artifacts in the dither range due to inverting our
relative colour viewpoint -- most obvious in 1-bit dither. */
relative color viewpoint -- most obvious in 1-bit dither. */
if (pixval1 > pixval2)
{
gint tmpval = pixval1;
......@@ -3333,12 +3333,12 @@ median_cut_pass2_fixed_dither_rgb (QuantizeObj *quantobj,
if (*cachep == 0)
fill_inverse_cmap_rgb (quantobj, histogram, R, G, B);
/* We now try to find a colour which, when mixed in some fashion
/* We now try to find a color which, when mixed in some fashion
with the closest match, yields something closer to the
desired colour. We do this by repeatedly extrapolating the
colour vector from one to the other until we find another
colour cell. Then we assess the distance of both mixer
colours from the intended colour to determine their relative
desired color. We do this by repeatedly extrapolating the
color vector from one to the other until we find another
color cell. Then we assess the distance of both mixer
colors from the intended color to determine their relative
probabilities of being chosen. */
pixval1 = *cachep - 1;
color1 = &quantobj->cmap[pixval1];
......@@ -3376,16 +3376,16 @@ median_cut_pass2_fixed_dither_rgb (QuantizeObj *quantobj,
if (quantobj->actual_number_of_colors <= 2
/* || pixval1 == pixval2 */) {
/* not enough colours to bother looking for an 'alternative'
colour (we may fail to do so anyway), so decide that
the alternative colour is simply the other cmap entry. */
/* not enough colors to bother looking for an 'alternative'
color (we may fail to do so anyway), so decide that
the alternative color is simply the other cmap entry. */
pixval2 = (pixval1 + 1) %
(quantobj->actual_number_of_colors);
}
/* always deterministically sort pixval1 and pixval2, to
avoid artifacts in the dither range due to inverting our
relative colour viewpoint -- most obvious in 1-bit dither. */
relative color viewpoint -- most obvious in 1-bit dither. */
if (pixval1 > pixval2)
{
gint tmpval = pixval1;
......@@ -3525,7 +3525,7 @@ median_cut_pass2_nodestruct_dither_rgb (QuantizeObj *quantobj,
(lastgreen == src[green_pix]) &&
(lastblue == src[blue_pix]))
{
/* same pixel colour as last time */
/* same pixel color as last time */
dest[INDEXED] = lastindex;
if (has_alpha)
dest[ALPHA_I] = 255;
......@@ -3547,12 +3547,12 @@ median_cut_pass2_nodestruct_dither_rgb (QuantizeObj *quantobj,
lastblue = src[blue_pix];
lastindex = i;
goto got_colour;
goto got_color;
}
}
g_error ("Non-existant colour was expected to "
"be in non-destructive colourmap.");
got_colour:
g_error ("Non-existant color was expected to "
"be in non-destructive colormap.");
got_color:
dest[INDEXED] = lastindex;
if (has_alpha)
dest[ALPHA_I] = 255;
......@@ -3890,7 +3890,7 @@ median_cut_pass2_rgb_init (QuantizeObj *quantobj)
/* Mark all indices as currently unused */
memset (quantobj->index_used_count, 0, 256 * sizeof (unsigned long));
/* Make a version of our discovered colourmap in linear space */
/* Make a version of our discovered colormap in linear space */
for (i = 0; i < quantobj->actual_number_of_colors; i++)
{
rgb_to_unshifted_lin (quantobj->cmap[i].red,
......@@ -3980,7 +3980,7 @@ median_cut_pass2_fs_dither_rgb (QuantizeObj *quantobj,
error_limiter = init_error_limit (quantobj->error_freedom);
range_limiter = range_array + 256;
/* find the bounding box of the palette colours --
/* find the bounding box of the palette colors --
we use this for hard-clamping our error-corrected
values so that we can't continuously accelerate outside
of our attainable gamut, which looks icky. */
......@@ -4194,7 +4194,7 @@ median_cut_pass2_fs_dither_rgb (QuantizeObj *quantobj,
}
else
{
/* colour pretty much undefined now; nullify error. */
/* color pretty much undefined now; nullify error. */
re = ge = be = 0;
}
#endif
......
......@@ -70,7 +70,7 @@ cie94 (gfloat* src1,
}
/*
* CIE 2000 delta E colour comparison
* CIE 2000 delta E color comparison
*/
static gdouble
delta_e (gfloat* src1,
......
......@@ -108,7 +108,7 @@ static GimpImageBaseType imagetype;
static GimpImageType drawabletype_alpha;
static guchar pixelstep;
static guchar *palette;
static gint ncolours;
static gint ncolors;
static operatingMode opmode;
......@@ -467,8 +467,8 @@ do_optimizations (GimpRunMode run_mode,
if (imagetype == GIMP_INDEXED)
{
palette = gimp_image_get_colormap (image_id, &ncolours);
gimp_image_set_colormap (new_image_id, palette, ncolours);
palette = gimp_image_get_colormap (image_id, &ncolors);
gimp_image_set_colormap (new_image_id, palette, ncolors);
}
#if 1
......@@ -483,7 +483,7 @@ do_optimizations (GimpRunMode run_mode,
guchar **green;
guchar **blue;
guint **count;
guint *num_colours;
guint *num_colors;
these_rows = g_new (guchar *, total_frames);
red = g_new (guchar *, total_frames);
......@@ -491,7 +491,7 @@ do_optimizations (GimpRunMode run_mode,
blue = g_new (guchar *, total_frames);
count = g_new (guint *, total_frames);
num_colours = g_new (guint, width);
num_colors = g_new (guint, width);
for (this_frame_num=0; this_frame_num<total_frames; this_frame_num++)
{
......@@ -506,7 +506,7 @@ do_optimizations (GimpRunMode run_mode,
for (row = 0; row < height; row++)
{
memset(num_colours, 0, width * sizeof(guint));
memset(num_colors, 0, width * sizeof(guint));
for (this_frame_num=0; this_frame_num<total_frames; this_frame_num++)
{
......@@ -534,7 +534,7 @@ do_optimizations (GimpRunMode run_mode,
if (these_rows[this_frame_num][i * pixelstep + pixelstep -1]
>= 128)
{
for (j=0; j<num_colours[i]; j++)
for (j=0; j<num_colors[i]; j++)
{
switch (pixelstep)
......@@ -565,17 +565,17 @@ do_optimizations (GimpRunMode run_mode,
}
}
count[num_colours[i]][i] = 1;
red[num_colours[i]][i] =
count[num_colors[i]][i] = 1;
red[num_colors[i]][i] =
these_rows[this_frame_num][i * pixelstep];
if (pixelstep == 4)
{
green[num_colours[i]][i] =
green[num_colors[i]][i] =
these_rows[this_frame_num][i * 4 +1];
blue[num_colours[i]][i] =
blue[num_colors[i]][i] =
these_rows[this_frame_num][i * 4 +2];
}
num_colours[i]++;
num_colors[i]++;
}
same:
/* nop */;
......@@ -587,7 +587,7 @@ do_optimizations (GimpRunMode run_mode,
guint best_count = 0;
guchar best_r = 255, best_g = 0, best_b = 255;
for (j=0; j<num_colours[i]; j++)
for (j=0; j<num_colors[i]; j++)
{
if (count[j][i] > best_count)
{
......@@ -631,7 +631,7 @@ do_optimizations (GimpRunMode run_mode,
g_free (green);
g_free (blue);
g_free (count);
g_free (num_colours);
g_free (num_colors);
}
#endif
......@@ -802,7 +802,7 @@ do_optimizations (GimpRunMode run_mode,
goto decided;
}
/* If 'last' and 'this' are opaque, we have
* to check if they're the same colour - we
* to check if they're the same color - we
* only have to keep the pixel if 'last' or
* 'this' are opaque and different.
*/
......
......@@ -159,7 +159,7 @@ static gint32 *layers = NULL;
static gint32 total_layers = 0;
static GimpImageBaseType imagetype;
static guchar *palette = NULL;
static gint ncolours;
static gint ncolors;
static GtkWidget *drawing_area = NULL;
static guchar *drawing_area_data = NULL;
......@@ -1098,7 +1098,7 @@ initialize (void)
if (imagetype == GIMP_INDEXED)
{
palette = gimp_image_get_colormap (image_id, &ncolours);
palette = gimp_image_get_colormap (image_id, &ncolors);
}
else if (imagetype == GIMP_GRAY)
{
......@@ -1109,7 +1109,7 @@ initialize (void)
for (i = 0; i < 256; i++)
palette[i * 3] = palette[i * 3 + 1] = palette[i * 3 + 2] = i;
ncolours = 256;
ncolors = 256;
}
if (!window)
......
......@@ -354,7 +354,7 @@ blindsapply (guchar *srow,
/* The angle is the conceptual 'rotation' of each of these segments */
/* Note the row is considered to be made up of a two dim array actual
* pixel locations and the RGB colour at these locations.
* pixel locations and the RGB color at these locations.
*/
/* In the process copy the src row to the destination row */
......
......@@ -23,7 +23,7 @@
* to another while keeping the original image visually unmodified.
*
* Such functionality is useful for creating graphics files for applications
* which expect certain indices to contain some specific colours.
* which expect certain indices to contain some specific colors.
*
*/
......
......@@ -22,10 +22,10 @@
/* This plugin performs almost the same operation as the 'contrast
* autostretch' plugin, except that it won't allow the colour channels
* autostretch' plugin, except that it won't allow the color channels
* to normalize independently. This is actually what most people probably
* want instead of contrast-autostretch; use c-a only if you wish to remove
* an undesirable colour-tint from a source image which is supposed to
* an undesirable color-tint from a source image which is supposed to
* contain pure-white and pure-black.
*/
......
......@@ -322,7 +322,7 @@ load_image (const gchar *file,
bpp; /* Bits per pixel */
gint height, width, /* Dimensions of image */
offx, offy, /* Layer offets */
colours; /* Number of colours */
colors; /* Number of colors */
gint32 image, /* Image */
layer; /* Layer */
......@@ -361,7 +361,7 @@ load_image (const gchar *file,
if (strncmp ((const gchar *) header, "KiSS", 4))
{
colours= 16;
colors= 16;
bpp = 4;
width = header[0] + (256 * header[1]);
height = header[2] + (256 * header[3]);
......@@ -393,7 +393,7 @@ load_image (const gchar *file,
case 4:
case 8:
case 32:
colours = (1 << bpp);
colors = (1 << bpp);
break;
default:
g_set_error (error, G_FILE_ERROR, G_FILE_ERROR_FAILED,
......@@ -579,20 +579,20 @@ load_image (const gchar *file,
if (fp != NULL)
{
colours = load_palette (palette_file, fp, palette, error);
colors = load_palette (palette_file, fp, palette, error);
fclose (fp);
if (colours < 0 || *error)
if (colors < 0 || *error)
return -1;
}
else
{
for (i= 0; i < colours; ++i)
for (i= 0; i < colors; ++i)
{
palette[i * 3] = palette[i * 3 + 1] = palette[i * 3 + 2]= i * 256 / colours;
palette[i * 3] = palette[i * 3 + 1] = palette[i * 3 + 2]= i * 256 / colors;
}
}
gimp_image_set_colormap (image, palette + 3, colours - 1);
gimp_image_set_colormap (image, palette + 3, colors - 1);
}
/* Now get everything redrawn and hand back the finished image */
......@@ -613,7 +613,7 @@ load_palette (const gchar *file,
guchar header[32]; /* File header */
guchar buffer[2];
guchar file_mark, bpp;
gint i, colours = 0;
gint i, colors = 0;
size_t n_read;
n_read = fread (header, 4, 1, fp);
......@@ -656,19 +656,19 @@ load_palette (const gchar *file,
return -1;
}
colours = header[8] + header[9] * 256;
if (colours != 16 && colours != 256)
colors = header[8] + header[9] * 256;
if (colors != 16 && colors != 256)
{
g_set_error (error, G_FILE_ERROR, G_FILE_ERROR_FAILED,
_("'%s': illegal number of colors: %u"),
gimp_filename_to_utf8 (file), colours);
gimp_filename_to_utf8 (file), colors);
return -1;
}
switch (bpp)
{
case 12:
for (i = 0; i < colours; ++i)
for (i = 0; i < colors; ++i)
{
n_read = fread (buffer, 1, 2, fp);
......@@ -687,7 +687,7 @@ load_palette (const gchar *file,
}
break;
case 24:
n_read = fread (palette, colours, 3, fp);
n_read = fread (palette, colors, 3, fp);
if (n_read < 3)
{
......@@ -703,9 +703,9 @@ load_palette (const gchar *file,
}
else
{
colours = 16;
colors = 16;
fseek (fp, 0, SEEK_SET);
for (i= 0; i < colours; ++i)
for (i= 0; i < colors; ++i)
{
n_read = fread (buffer, 1, 2, fp);
......@@ -723,7 +723,7 @@ load_palette (const gchar *file,
}
}
return colours;
return colors;
}
static gboolean
......@@ -739,7 +739,7 @@ save_image (const gchar *file,
gint height;
guchar header[32]; /* File header */
gint bpp; /* Bit per pixel */
gint colours, type; /* Number of colours, type of layer */
gint colors, type; /* Number of colors, type of layer */
gint offx, offy; /* Layer offsets */
guchar *buf; /* Temporary buffer */
guchar *line; /* Pixel data */
......@@ -789,9 +789,9 @@ save_image (const gchar *file,
/* Work out whether to save as 8bit or 4bit */
if (bpp < 32)
{
g_free (gimp_image_get_colormap (image, &colours));
g_free (gimp_image_get_colormap (image, &colors));
if (colours > 15)
if (colors > 15)
{
header[5] = 8;
}
......@@ -841,7 +841,7 @@ save_image (const gchar *file,
fwrite (buf, width, 4, fp);
}
else if (colours > 16)
else if (colors > 16)
{
for (j = 0, k = 0; j < width * 2; j += 2, ++k)
{
......
......@@ -60,7 +60,7 @@
*
* - PDB stuff for comments
*
* - Remove unused colourmap entries for GRAYSCALE images.
* - Remove unused colormap entries for GRAYSCALE images.
*/
#include "config.h"
......@@ -219,8 +219,8 @@ run (const gchar *name,
* So if we're not careful, repeated load/save of a transparent GIF
* without intermediate indexed->RGB->indexed pumps up the number of
* bits used, as we add an index each time for the transparent
* colour. Ouch. We either do some heavier analysis at save-time,
* or trim down the number of GIMP colours at load-time. We do the
* color. Ouch. We either do some heavier analysis at save-time,
* or trim down the number of GIMP colors at load-time. We do the
* latter for now.
*/
#ifdef GIFDEBUG
......@@ -970,7 +970,7 @@ ReadImage (FILE *fd,
frame_number);
gimp_progress_pulse ();
/* If the colourmap is now different, we have to promote to RGB! */
/* If the colormap is now different, we have to promote to RGB! */
if (! promote_to_rgb)
{
for (i = 0; i < ncols; i++)
......
......@@ -343,7 +343,7 @@ run (const gchar *name,
typedef int (*ifunptr) (int, int);
static gint find_unused_ia_colour (const guchar *pixels,
static gint find_unused_ia_color (const guchar *pixels,
gint numpixels,
gint num_indices,
gint *colors);
......@@ -395,7 +395,7 @@ static void flush_char (void);
static gint
find_unused_ia_colour (const guchar *pixels,
find_unused_ia_color (const guchar *pixels,
gint numpixels,
gint num_indices,
gint *colors)
......@@ -422,21 +422,21 @@ find_unused_ia_colour (const guchar *pixels,
if (! ix_used[i])
{
#ifdef GIFDEBUG
g_printerr ("GIF: Found unused colour index %d.\n", (int) i);
g_printerr ("GIF: Found unused color index %d.\n", (int) i);
#endif
return i;
}
}
/* Couldn't find an unused colour index within the number of
/* Couldn't find an unused color index within the number of
bits per pixel we wanted. Will have to increment the number
of colours in the image and assign a transparent pixel there. */
of colors in the image and assign a transparent pixel there. */
if (*colors < 256)
{
(*colors)++;
g_printerr ("GIF: 2nd pass "
"- Increasing bounds and using colour index %d.\n",
"- Increasing bounds and using color index %d.\n",
*colors - 1);
return ((*colors) - 1);
}
......@@ -455,7 +455,7 @@ special_flatten_indexed_alpha (guchar *pixels,
guint32 i;
/* Each transparent pixel in the image is mapped to a uniform value for
encoding, if image already has <=255 colours */
encoding, if image already has <=255 colors */
if (transparent == -1) /* tough, no indices left for the trans. index */
{
......@@ -737,7 +737,7 @@ save_image (const gchar *filename,
/* find earliest index in palette which is closest to the background
colour, and ATTEMPT to use that as the GIF's default background colour. */
color, and ATTEMPT to use that as the GIF's default background color. */
for (i = 255; i >= 0; --i)
{
guint local_error = 0;
......@@ -787,7 +787,7 @@ save_image (const gchar *filename,
if (drawable_type == GIMP_INDEXEDA_IMAGE)
{
g_printerr ("GIF: Too many colours?\n");
g_printerr ("GIF: Too many colors?\n");
}
}
......@@ -841,7 +841,7 @@ save_image (const gchar *filename,
image, for a transparency index. */
transparent =
find_unused_ia_colour (pixels,
find_unused_ia_color (pixels,
cols * rows,
bpp_to_colors (colors_to_bpp (colors)),
&colors);
......@@ -1221,7 +1221,7 @@ colors_to_bpp (int colors)
bpp = 8;
else
{
g_warning ("GIF: colors_to_bpp - Eep! too many colours: %d\n", colors);
g_warning ("GIF: colors_to_bpp - Eep! too many colors: %d\n", colors);
return 8;
}
......@@ -1409,7 +1409,7 @@ gif_encode_header (FILE *fp,
put_word (RHeight, fp);
/*
* Indicate that there is a global colour map
* Indicate that there is a global color map
*/
B = 0x80; /* Yes, there is a color map */
......@@ -1429,7 +1429,7 @@ gif_encode_header (FILE *fp,
fputc (B, fp);
/*
* Write out the Background colour
* Write out the Background color
*/
fputc (Background, fp);
......@@ -1439,7 +1439,7 @@ gif_encode_header (FILE *fp,