Commit 88e0cc31 authored by Marc Lehmann's avatar Marc Lehmann
Browse files

api change #2, fix #1

parent 1298f319
Sun Oct 24 16:49:13 CEST 1999 Marc Lehmann <pcg@goof.com>
* tools/pdbgen/pdb/drawable.pdb, all calls: fixed some improperly
renamed pdb functions, most notably gimp_drawable_color.
Sun Oct 24 22:10:16 MEST 1999 Sven Neumann <sven@gimp.org>
 
* app/channels_dialog.c
......@@ -197,6 +202,7 @@ Thu Oct 19 05:30:11 BST 1999 Nick Lamb <njl195@zepler.org>
 
* app/image_new.c: Still using RGB_IMAGE instead of GIMAGE (!)
>>>>>>> 1.1725
Mon Oct 18 21:24:47 BST 1999 Andy Thomas <alt@gimp.org>
 
* app/bezier_select.c
......@@ -215,8 +221,13 @@ Mon Oct 18 21:24:47 BST 1999 Andy Thomas <alt@gimp.org>
not on the curve the "new point" option will become selected and the
new point will be added.
 
<<<<<<< ChangeLog
2) The "new point" option is defaulted to on when a new image is created
or a new image is selected from the image menu.
=======
2) The "new point" option is defaulted to on when a new image is
created or a new image is selected from the image menu.
>>>>>>> 1.1725
 
3) Move and flip tool now effect the path if it is locked.
 
......@@ -5913,7 +5924,7 @@ Sat May 29 23:43:56 PDT 1999 Manish Singh <yosh@gimp.org>
 
* libgimp/stdplugins-intl.h: #include <locale.h>
 
1999-05-30 Jens Lauterbacher <jens@tellux.de>
1999-05-30 Jens Lautenbacher <jens@tellux.de>
Simon Budig <Simon.Budig@unix-ag.org>
Michael Natterer <mitschel@cs.tu-berlin.de>
Adam D. Moss <adam@gimp.org>
......
......@@ -398,7 +398,7 @@ desaturate_invoker (Argument *args)
if (success)
{
if (gimp_drawable_color (drawable))
if (gimp_drawable_is_rgb (drawable))
desaturate (drawable);
else
success = FALSE;
......@@ -581,7 +581,7 @@ curves_spline_invoker (Argument *args)
cd.drawable = drawable;
cd.channel = channel;
cd.color = gimp_drawable_color (drawable);
cd.color = gimp_drawable_is_rgb (drawable);
cd.curve_type = SMOOTH;
for (j = 0; j < num_points / 2; j++)
......@@ -691,7 +691,7 @@ curves_explicit_invoker (Argument *args)
cd.drawable = drawable;
cd.channel = channel;
cd.color = gimp_drawable_color (drawable);
cd.color = gimp_drawable_is_rgb (drawable);
for (j = 0; j < 256; j++)
cd.curve[cd.channel][j] = curve[j];
......@@ -929,7 +929,7 @@ histogram_invoker (Argument *args)
htd.shell = NULL;
htd.channel = channel;
htd.drawable = drawable;
htd.color = gimp_drawable_color (drawable);
htd.color = gimp_drawable_is_rgb (drawable);
htd.histogram = histogram_widget_new (HISTOGRAM_WIDTH,
HISTOGRAM_HEIGHT);
......@@ -1201,7 +1201,7 @@ threshold_invoker (Argument *args)
success = FALSE;
else
{
td.color = gimp_drawable_color (drawable);
td.color = gimp_drawable_is_rgb (drawable);
td.low_threshold = low_threshold;
td.high_threshold = high_threshold;
......
......@@ -522,7 +522,7 @@ gimp_drawable_get_tattoo (const GimpDrawable *drawable)
}
gboolean
gimp_drawable_color (GimpDrawable *drawable)
gimp_drawable_is_rgb (GimpDrawable *drawable)
{
if (gimp_drawable_type (drawable) == RGBA_GIMAGE ||
gimp_drawable_type (drawable) == RGB_GIMAGE)
......
......@@ -50,7 +50,7 @@ gint gimp_drawable_clean (GimpDrawable *);
gboolean gimp_drawable_has_alpha (GimpDrawable *);
GimpImageType gimp_drawable_type (GimpDrawable *);
GimpImageType gimp_drawable_type_with_alpha (GimpDrawable *);
gboolean gimp_drawable_color (GimpDrawable *);
gboolean gimp_drawable_is_rgb (GimpDrawable *);
gboolean gimp_drawable_is_gray (GimpDrawable *);
gboolean gimp_drawable_is_indexed (GimpDrawable *);
TileManager * gimp_drawable_data (GimpDrawable *);
......
......@@ -36,7 +36,7 @@ void drawable_apply_image (GimpDrawable *, gint, gint, gint, gint,
#define drawable_type gimp_drawable_type
#define drawable_has_alpha gimp_drawable_has_alpha
#define drawable_type_with_alpha gimp_drawable_type_with_alpha
#define drawable_color gimp_drawable_color
#define drawable_color gimp_drawable_is_rgb
#define drawable_gray gimp_drawable_is_gray
#define drawable_indexed gimp_drawable_is_indexed
#define drawable_data gimp_drawable_data
......
......@@ -35,9 +35,9 @@ static ProcRecord drawable_image_proc;
static ProcRecord drawable_type_proc;
static ProcRecord drawable_has_alpha_proc;
static ProcRecord drawable_type_with_alpha_proc;
static ProcRecord drawable_color_proc;
static ProcRecord drawable_gray_proc;
static ProcRecord drawable_indexed_proc;
static ProcRecord drawable_is_rgb_proc;
static ProcRecord drawable_is_gray_proc;
static ProcRecord drawable_is_indexed_proc;
static ProcRecord drawable_bytes_proc;
static ProcRecord drawable_width_proc;
static ProcRecord drawable_height_proc;
......@@ -61,9 +61,9 @@ register_drawable_procs (void)
procedural_db_register (&drawable_type_proc);
procedural_db_register (&drawable_has_alpha_proc);
procedural_db_register (&drawable_type_with_alpha_proc);
procedural_db_register (&drawable_color_proc);
procedural_db_register (&drawable_gray_proc);
procedural_db_register (&drawable_indexed_proc);
procedural_db_register (&drawable_is_rgb_proc);
procedural_db_register (&drawable_is_gray_proc);
procedural_db_register (&drawable_is_indexed_proc);
procedural_db_register (&drawable_bytes_proc);
procedural_db_register (&drawable_width_proc);
procedural_db_register (&drawable_height_proc);
......@@ -528,20 +528,20 @@ static ProcRecord drawable_type_with_alpha_proc =
};
static Argument *
drawable_color_invoker (Argument *args)
drawable_is_rgb_invoker (Argument *args)
{
Argument *return_args;
GimpDrawable *drawable;
drawable = gimp_drawable_get_ID (args[0].value.pdb_int);
return_args = procedural_db_return_args (&drawable_color_proc, TRUE);
return_args = procedural_db_return_args (&drawable_is_rgb_proc, TRUE);
return_args[1].value.pdb_int = drawable_color (drawable);
return return_args;
}
static ProcArg drawable_color_inargs[] =
static ProcArg drawable_is_rgb_inargs[] =
{
{
PDB_DRAWABLE,
......@@ -550,7 +550,7 @@ static ProcArg drawable_color_inargs[] =
}
};
static ProcArg drawable_color_outargs[] =
static ProcArg drawable_is_rgb_outargs[] =
{
{
PDB_INT32,
......@@ -559,9 +559,9 @@ static ProcArg drawable_color_outargs[] =
}
};
static ProcRecord drawable_color_proc =
static ProcRecord drawable_is_rgb_proc =
{
"gimp_drawable_color",
"gimp_drawable_is_rgb",
"Returns whether the drawable is an RGB type.",
"This procedure returns non-zero if the specified drawable is of type { RGB, RGBA }.",
"Spencer Kimball & Peter Mattis",
......@@ -569,27 +569,27 @@ static ProcRecord drawable_color_proc =
"1995-1996",
PDB_INTERNAL,
1,
drawable_color_inargs,
drawable_is_rgb_inargs,
1,
drawable_color_outargs,
{ { drawable_color_invoker } }
drawable_is_rgb_outargs,
{ { drawable_is_rgb_invoker } }
};
static Argument *
drawable_gray_invoker (Argument *args)
drawable_is_gray_invoker (Argument *args)
{
Argument *return_args;
GimpDrawable *drawable;
drawable = gimp_drawable_get_ID (args[0].value.pdb_int);
return_args = procedural_db_return_args (&drawable_gray_proc, TRUE);
return_args = procedural_db_return_args (&drawable_is_gray_proc, TRUE);
return_args[1].value.pdb_int = drawable_gray (drawable);
return return_args;
}
static ProcArg drawable_gray_inargs[] =
static ProcArg drawable_is_gray_inargs[] =
{
{
PDB_DRAWABLE,
......@@ -598,7 +598,7 @@ static ProcArg drawable_gray_inargs[] =
}
};
static ProcArg drawable_gray_outargs[] =
static ProcArg drawable_is_gray_outargs[] =
{
{
PDB_INT32,
......@@ -607,9 +607,9 @@ static ProcArg drawable_gray_outargs[] =
}
};
static ProcRecord drawable_gray_proc =
static ProcRecord drawable_is_gray_proc =
{
"gimp_drawable_gray",
"gimp_drawable_is_gray",
"Returns whether the drawable is a grayscale type.",
"This procedure returns non-zero if the specified drawable is of type { Gray, GrayA }.",
"Spencer Kimball & Peter Mattis",
......@@ -617,27 +617,27 @@ static ProcRecord drawable_gray_proc =
"1995-1996",
PDB_INTERNAL,
1,
drawable_gray_inargs,
drawable_is_gray_inargs,
1,
drawable_gray_outargs,
{ { drawable_gray_invoker } }
drawable_is_gray_outargs,
{ { drawable_is_gray_invoker } }
};
static Argument *
drawable_indexed_invoker (Argument *args)
drawable_is_indexed_invoker (Argument *args)
{
Argument *return_args;
GimpDrawable *drawable;
drawable = gimp_drawable_get_ID (args[0].value.pdb_int);
return_args = procedural_db_return_args (&drawable_indexed_proc, TRUE);
return_args = procedural_db_return_args (&drawable_is_indexed_proc, TRUE);
return_args[1].value.pdb_int = drawable_indexed (drawable);
return return_args;
}
static ProcArg drawable_indexed_inargs[] =
static ProcArg drawable_is_indexed_inargs[] =
{
{
PDB_DRAWABLE,
......@@ -646,7 +646,7 @@ static ProcArg drawable_indexed_inargs[] =
}
};
static ProcArg drawable_indexed_outargs[] =
static ProcArg drawable_is_indexed_outargs[] =
{
{
PDB_INT32,
......@@ -655,9 +655,9 @@ static ProcArg drawable_indexed_outargs[] =
}
};
static ProcRecord drawable_indexed_proc =
static ProcRecord drawable_is_indexed_proc =
{
"gimp_drawable_indexed",
"gimp_drawable_is_indexed",
"Returns whether the drawable is an indexed type.",
"This procedure returns non-zero if the specified drawable is of type { Indexed, IndexedA }.",
"Spencer Kimball & Peter Mattis",
......@@ -665,10 +665,10 @@ static ProcRecord drawable_indexed_proc =
"1995-1996",
PDB_INTERNAL,
1,
drawable_indexed_inargs,
drawable_is_indexed_inargs,
1,
drawable_indexed_outargs,
{ { drawable_indexed_invoker } }
drawable_is_indexed_outargs,
{ { drawable_is_indexed_invoker } }
};
static Argument *
......
......@@ -522,7 +522,7 @@ gimp_drawable_get_tattoo (const GimpDrawable *drawable)
}
gboolean
gimp_drawable_color (GimpDrawable *drawable)
gimp_drawable_is_rgb (GimpDrawable *drawable)
{
if (gimp_drawable_type (drawable) == RGBA_GIMAGE ||
gimp_drawable_type (drawable) == RGB_GIMAGE)
......
......@@ -50,7 +50,7 @@ gint gimp_drawable_clean (GimpDrawable *);
gboolean gimp_drawable_has_alpha (GimpDrawable *);
GimpImageType gimp_drawable_type (GimpDrawable *);
GimpImageType gimp_drawable_type_with_alpha (GimpDrawable *);
gboolean gimp_drawable_color (GimpDrawable *);
gboolean gimp_drawable_is_rgb (GimpDrawable *);
gboolean gimp_drawable_is_gray (GimpDrawable *);
gboolean gimp_drawable_is_indexed (GimpDrawable *);
TileManager * gimp_drawable_data (GimpDrawable *);
......
......@@ -740,7 +740,7 @@ come a long way in two years.
(plug-in-gauss-rle 1 img disp-map blur TRUE TRUE)
(gimp-levels img disp-map 0 0 255 1.0 96 255)
(if (= (car (gimp-drawable-color bg-layer)) 1)
(if (= (car (gimp-drawable-is-rgb bg-layer)) 1)
(gimp-convert-rgb img))
(gimp-image-add-layer img bg-layer 2)
......
......@@ -36,7 +36,7 @@ EXPORTS
gimp_drawable_parasite_attach
gimp_drawable_bpp
gimp_drawable_is_channel
gimp_drawable_color
gimp_drawable_is_rgb
gimp_drawable_delete
gimp_drawable_detach
gimp_drawable_parasite_detach
......
......@@ -694,7 +694,7 @@ guint gimp_drawable_bpp (gint32 drawable_ID);
GDrawableType gimp_drawable_type (gint32 drawable_ID);
gint gimp_drawable_visible (gint32 drawable_ID);
gint gimp_drawable_is_channel (gint32 drawable_ID);
gint gimp_drawable_color (gint32 drawable_ID);
gint gimp_drawable_is_rgb (gint32 drawable_ID);
gint gimp_drawable_is_gray (gint32 drawable_ID);
gint gimp_drawable_has_alpha (gint32 drawable_ID);
gint gimp_drawable_is_indexed (gint32 drawable_ID);
......
......@@ -285,13 +285,13 @@ gimp_drawable_is_channel (gint32 drawable_ID)
}
gint
gimp_drawable_color (gint32 drawable_ID)
gimp_drawable_is_rgb (gint32 drawable_ID)
{
GParam *return_vals;
int nreturn_vals;
int result;
return_vals = gimp_run_procedure ("gimp_drawable_color",
return_vals = gimp_run_procedure ("gimp_drawable_is_rgb",
&nreturn_vals,
PARAM_DRAWABLE, drawable_ID,
PARAM_END);
......
......@@ -285,13 +285,13 @@ gimp_drawable_is_channel (gint32 drawable_ID)
}
gint
gimp_drawable_color (gint32 drawable_ID)
gimp_drawable_is_rgb (gint32 drawable_ID)
{
GParam *return_vals;
int nreturn_vals;
int result;
return_vals = gimp_run_procedure ("gimp_drawable_color",
return_vals = gimp_run_procedure ("gimp_drawable_is_rgb",
&nreturn_vals,
PARAM_DRAWABLE, drawable_ID,
PARAM_END);
......
......@@ -374,7 +374,7 @@ run (char *name,
if (status == STATUS_SUCCESS)
{
/* Make sure that the drawable is indexed or RGB color */
if (gimp_drawable_color (drawable->id))
if (gimp_drawable_is_rgb (drawable->id))
{
gimp_progress_init (_("AlienMap: Transforming ..."));
......
......@@ -387,7 +387,7 @@ run (char *name,
if (status == STATUS_SUCCESS)
{
/* Make sure that the drawable is indexed or RGB_MODEL color */
if (gimp_drawable_color (drawable->id))
if (gimp_drawable_is_rgb (drawable->id))
{
gimp_progress_init (_("AlienMap2: Transforming ..."));
......
......@@ -297,7 +297,7 @@ run(char *name,
if (status == STATUS_SUCCESS) {
/* Make sure that the drawable is indexed or RGB color */
if (gimp_drawable_color(drawable->id)) {
if (gimp_drawable_is_rgb(drawable->id)) {
gimp_progress_init("Rendering fractal...");
/* Set the tile cache size */
......
......@@ -226,7 +226,7 @@ static void run(gchar *name,
/* Make sure that the drawable is RGBA or RGB color */
/* ================================================ */
if (gimp_drawable_color(drawable->id))
if (gimp_drawable_is_rgb(drawable->id))
{
/* Set the tile cache size */
/* ======================= */
......
......@@ -568,7 +568,7 @@ gint box_constrain(gint32 image_id, gint32 drawable_id, gpointer data)
if (drawable_id == -1)
return(TRUE);
return (gimp_drawable_color(drawable_id) && !gimp_drawable_is_indexed(drawable_id));
return (gimp_drawable_is_rgb(drawable_id) && !gimp_drawable_is_indexed(drawable_id));
}
void box_drawable_callback(gint32 id, gpointer data)
......@@ -585,7 +585,7 @@ gint cylinder_constrain(gint32 image_id, gint32 drawable_id, gpointer data)
if (drawable_id == -1)
return(TRUE);
return (gimp_drawable_color(drawable_id) && !gimp_drawable_is_indexed(drawable_id));
return (gimp_drawable_is_rgb(drawable_id) && !gimp_drawable_is_indexed(drawable_id));
}
void cylinder_drawable_callback(gint32 id, gpointer data)
......
......@@ -155,7 +155,7 @@ run (char *name,
if (status == STATUS_SUCCESS) {
/* Make sure that the drawable is RGB color */
if (gimp_drawable_color (drawable->id)) {
if (gimp_drawable_is_rgb (drawable->id)) {
gimp_progress_init ("borderaverage");
borderaverage (drawable, &result_color[0], &result_color[1], &result_color[2]);
......
......@@ -98,7 +98,7 @@ static void run(char *name, int n_params, GParam * param, int *nreturn_vals,
image_id = param[1].data.d_image;
/* Make sure that the drawable is gray or RGB color */
if (gimp_drawable_color(drawable->id) ||
if (gimp_drawable_is_rgb(drawable->id) ||
gimp_drawable_is_gray(drawable->id) ||
gimp_drawable_is_indexed(drawable->id))
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment