Commit 396f92b8 authored by Michael Natterer's avatar Michael Natterer 😴 Committed by Michael Natterer

return the procedure.

2006-03-29  Michael Natterer  <mitch@gimp.org>

	* app/pdb/procedural_db.[ch] (procedural_db_init_proc): return the
	procedure.

	* tools/pdbgen/app.pl: use a local ProcRecord* variable so the
	generated code becomes more readable.

	* app/pdb/*_cmds.c: regenerated.
parent d624560f
2006-03-29 Michael Natterer <mitch@gimp.org>
* app/pdb/procedural_db.[ch] (procedural_db_init_proc): return the
procedure.
* tools/pdbgen/app.pl: use a local ProcRecord* variable so the
generated code becomes more readable.
* app/pdb/*_cmds.c: regenerated.
2006-03-29 Michael Natterer <mitch@gimp.org>
* libgimp/gimp.c (gimp_run_procedure2): add newline to g_printerr().
......
This diff is collapsed.
......@@ -37,11 +37,13 @@ static ProcRecord brushes_set_popup_proc;
void
register_brush_select_procs (Gimp *gimp)
{
ProcRecord *procedure;
/*
* brushes_popup
*/
procedural_db_init_proc (&brushes_popup_proc, 6, 0);
procedural_db_add_argument (&brushes_popup_proc,
procedure = procedural_db_init_proc (&brushes_popup_proc, 6, 0);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("brush-callback",
"brush callback",
......@@ -49,7 +51,7 @@ register_brush_select_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("popup-title",
"popup title",
......@@ -57,7 +59,7 @@ register_brush_select_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("initial-brush",
"initial brush",
......@@ -65,21 +67,21 @@ register_brush_select_procs (Gimp *gimp)
FALSE, TRUE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_FLOAT,
g_param_spec_double ("opacity",
"opacity",
"The initial opacity of the brush",
0, 100, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("spacing",
"spacing",
"The initial spacing of the brush (if < 0 then use brush default spacing)",
G_MININT32, 1000, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_enum ("paint-mode",
"paint mode",
......@@ -87,13 +89,13 @@ register_brush_select_procs (Gimp *gimp)
GIMP_TYPE_LAYER_MODE_EFFECTS,
GIMP_NORMAL_MODE,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &brushes_popup_proc);
procedural_db_register (gimp, procedure);
/*
* brushes_close_popup
*/
procedural_db_init_proc (&brushes_close_popup_proc, 1, 0);
procedural_db_add_argument (&brushes_close_popup_proc,
procedure = procedural_db_init_proc (&brushes_close_popup_proc, 1, 0);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("brush-callback",
"brush callback",
......@@ -101,13 +103,13 @@ register_brush_select_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &brushes_close_popup_proc);
procedural_db_register (gimp, procedure);
/*
* brushes_set_popup
*/
procedural_db_init_proc (&brushes_set_popup_proc, 5, 0);
procedural_db_add_argument (&brushes_set_popup_proc,
procedure = procedural_db_init_proc (&brushes_set_popup_proc, 5, 0);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("brush-callback",
"brush callback",
......@@ -115,7 +117,7 @@ register_brush_select_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_set_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("brush-name",
"brush name",
......@@ -123,21 +125,21 @@ register_brush_select_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_set_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_FLOAT,
g_param_spec_double ("opacity",
"opacity",
"The initial opacity of the brush",
0, 100, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_set_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("spacing",
"spacing",
"The initial spacing of the brush (if < 0 then use brush default spacing)",
G_MININT32, 1000, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&brushes_set_popup_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_enum ("paint-mode",
"paint mode",
......@@ -145,7 +147,7 @@ register_brush_select_procs (Gimp *gimp)
GIMP_TYPE_LAYER_MODE_EFFECTS,
GIMP_NORMAL_MODE,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &brushes_set_popup_proc);
procedural_db_register (gimp, procedure);
}
......
......@@ -46,17 +46,19 @@ static ProcRecord brushes_get_brush_data_proc;
void
register_brushes_procs (Gimp *gimp)
{
ProcRecord *procedure;
/*
* brushes_refresh
*/
procedural_db_init_proc (&brushes_refresh_proc, 0, 0);
procedural_db_register (gimp, &brushes_refresh_proc);
procedure = procedural_db_init_proc (&brushes_refresh_proc, 0, 0);
procedural_db_register (gimp, procedure);
/*
* brushes_get_list
*/
procedural_db_init_proc (&brushes_get_list_proc, 1, 2);
procedural_db_add_argument (&brushes_get_list_proc,
procedure = procedural_db_init_proc (&brushes_get_list_proc, 1, 2);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("filter",
"filter",
......@@ -64,26 +66,26 @@ register_brushes_procs (Gimp *gimp)
FALSE, TRUE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_list_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("num-brushes",
"num brushes",
"The number of brushes in the brush list",
0, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_list_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_STRINGARRAY,
g_param_spec_pointer ("brush-list",
"brush list",
"The list of brush names",
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &brushes_get_list_proc);
procedural_db_register (gimp, procedure);
/*
* brushes_get_brush
*/
procedural_db_init_proc (&brushes_get_brush_proc, 0, 4);
procedural_db_add_return_value (&brushes_get_brush_proc,
procedure = procedural_db_init_proc (&brushes_get_brush_proc, 0, 4);
procedural_db_add_return_value (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("name",
"name",
......@@ -91,60 +93,60 @@ register_brushes_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("width",
"width",
"The brush width",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("height",
"height",
"The brush height",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("spacing",
"spacing",
"The brush spacing (0 <= spacing <= 1000)",
0, 1000, 0,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &brushes_get_brush_proc);
procedural_db_register (gimp, procedure);
/*
* brushes_get_spacing
*/
procedural_db_init_proc (&brushes_get_spacing_proc, 0, 1);
procedural_db_add_return_value (&brushes_get_spacing_proc,
procedure = procedural_db_init_proc (&brushes_get_spacing_proc, 0, 1);
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("spacing",
"spacing",
"The brush spacing (0 <= spacing <= 1000)",
0, 1000, 0,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &brushes_get_spacing_proc);
procedural_db_register (gimp, procedure);
/*
* brushes_set_spacing
*/
procedural_db_init_proc (&brushes_set_spacing_proc, 1, 0);
procedural_db_add_argument (&brushes_set_spacing_proc,
procedure = procedural_db_init_proc (&brushes_set_spacing_proc, 1, 0);
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("spacing",
"spacing",
"The brush spacing (0 <= spacing <= 1000)",
0, 1000, 0,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &brushes_set_spacing_proc);
procedural_db_register (gimp, procedure);
/*
* brushes_get_brush_data
*/
procedural_db_init_proc (&brushes_get_brush_data_proc, 1, 8);
procedural_db_add_argument (&brushes_get_brush_data_proc,
procedure = procedural_db_init_proc (&brushes_get_brush_data_proc, 1, 8);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("name",
"name",
......@@ -152,7 +154,7 @@ register_brushes_procs (Gimp *gimp)
FALSE, TRUE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_data_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("actual-name",
"actual name",
......@@ -160,21 +162,21 @@ register_brushes_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_data_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_FLOAT,
g_param_spec_double ("opacity",
"opacity",
"The brush opacity (0 <= opacity <= 100)",
0, 100, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_data_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("spacing",
"spacing",
"The brush spacing (0 <= spacing <= 1000)",
0, 1000, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_data_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_enum ("paint-mode",
"paint mode",
......@@ -182,34 +184,34 @@ register_brushes_procs (Gimp *gimp)
GIMP_TYPE_LAYER_MODE_EFFECTS,
GIMP_NORMAL_MODE,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_data_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("width",
"width",
"The brush width",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_data_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("height",
"height",
"The brush height",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_data_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("length",
"length",
"Length of brush mask data",
0, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&brushes_get_brush_data_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT8ARRAY,
g_param_spec_pointer ("mask-data",
"mask data",
"The brush mask data",
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &brushes_get_brush_data_proc);
procedural_db_register (gimp, procedure);
}
......
......@@ -45,11 +45,13 @@ static ProcRecord buffer_get_image_type_proc;
void
register_buffer_procs (Gimp *gimp)
{
ProcRecord *procedure;
/*
* buffers_get_list
*/
procedural_db_init_proc (&buffers_get_list_proc, 1, 2);
procedural_db_add_argument (&buffers_get_list_proc,
procedure = procedural_db_init_proc (&buffers_get_list_proc, 1, 2);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("filter",
"filter",
......@@ -57,26 +59,26 @@ register_buffer_procs (Gimp *gimp)
FALSE, TRUE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&buffers_get_list_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("num-buffers",
"num buffers",
"The number of buffers",
0, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&buffers_get_list_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_STRINGARRAY,
g_param_spec_pointer ("buffer-list",
"buffer list",
"The list of buffer names",
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &buffers_get_list_proc);
procedural_db_register (gimp, procedure);
/*
* buffer_rename
*/
procedural_db_init_proc (&buffer_rename_proc, 2, 1);
procedural_db_add_argument (&buffer_rename_proc,
procedure = procedural_db_init_proc (&buffer_rename_proc, 2, 1);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("buffer-name",
"buffer name",
......@@ -84,7 +86,7 @@ register_buffer_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&buffer_rename_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("new-name",
"new name",
......@@ -92,7 +94,7 @@ register_buffer_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&buffer_rename_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("real-name",
"real name",
......@@ -100,13 +102,13 @@ register_buffer_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &buffer_rename_proc);
procedural_db_register (gimp, procedure);
/*
* buffer_delete
*/
procedural_db_init_proc (&buffer_delete_proc, 1, 0);
procedural_db_add_argument (&buffer_delete_proc,
procedure = procedural_db_init_proc (&buffer_delete_proc, 1, 0);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("buffer-name",
"buffer name",
......@@ -114,13 +116,13 @@ register_buffer_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &buffer_delete_proc);
procedural_db_register (gimp, procedure);
/*
* buffer_get_width
*/
procedural_db_init_proc (&buffer_get_width_proc, 1, 1);
procedural_db_add_argument (&buffer_get_width_proc,
procedure = procedural_db_init_proc (&buffer_get_width_proc, 1, 1);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("buffer-name",
"buffer name",
......@@ -128,20 +130,20 @@ register_buffer_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&buffer_get_width_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("width",
"width",
"The buffer width",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &buffer_get_width_proc);
procedural_db_register (gimp, procedure);
/*
* buffer_get_height
*/
procedural_db_init_proc (&buffer_get_height_proc, 1, 1);
procedural_db_add_argument (&buffer_get_height_proc,
procedure = procedural_db_init_proc (&buffer_get_height_proc, 1, 1);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("buffer-name",
"buffer name",
......@@ -149,20 +151,20 @@ register_buffer_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&buffer_get_height_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("height",
"height",
"The buffer height",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &buffer_get_height_proc);
procedural_db_register (gimp, procedure);
/*
* buffer_get_bytes
*/
procedural_db_init_proc (&buffer_get_bytes_proc, 1, 1);
procedural_db_add_argument (&buffer_get_bytes_proc,
procedure = procedural_db_init_proc (&buffer_get_bytes_proc, 1, 1);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("buffer-name",
"buffer name",
......@@ -170,20 +172,20 @@ register_buffer_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&buffer_get_bytes_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("bytes",
"bytes",
"The buffer bpp",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &buffer_get_bytes_proc);
procedural_db_register (gimp, procedure);
/*
* buffer_get_image_type
*/
procedural_db_init_proc (&buffer_get_image_type_proc, 1, 1);
procedural_db_add_argument (&buffer_get_image_type_proc,
procedure = procedural_db_init_proc (&buffer_get_image_type_proc, 1, 1);
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("buffer-name",
"buffer name",
......@@ -191,7 +193,7 @@ register_buffer_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&buffer_get_image_type_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_INT32,
g_param_spec_enum ("image-type",
"image type",
......@@ -199,7 +201,7 @@ register_buffer_procs (Gimp *gimp)
GIMP_TYPE_IMAGE_BASE_TYPE,
GIMP_RGB,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &buffer_get_image_type_proc);
procedural_db_register (gimp, procedure);
}
......
......@@ -47,32 +47,34 @@ static ProcRecord channel_set_color_proc;
void
register_channel_procs (Gimp *gimp)
{
ProcRecord *procedure;
/*
* channel_new
*/
procedural_db_init_proc (&channel_new_proc, 6, 1);
procedural_db_add_argument (&channel_new_proc,
procedure = procedural_db_init_proc (&channel_new_proc, 6, 1);
procedural_db_add_argument (procedure,
GIMP_PDB_IMAGE,
gimp_param_spec_image_id ("image",
"image",
"The image to which to add the channel",
gimp,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_new_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("width",
"width",
"The channel width (1 <= width)",
1, G_MAXINT32, 1,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_new_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("height",
"height",
"The channel height (1 <= height)",
1, G_MAXINT32, 1,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_new_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("name",
"name",
......@@ -80,21 +82,21 @@ register_channel_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_new_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_FLOAT,
g_param_spec_double ("opacity",
"opacity",
"The channel opacity (0 <= opacity <= 100)",
0, 100, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_new_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_COLOR,
gimp_param_spec_rgb ("color",
"color",
"The channel compositing color",
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&channel_new_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_CHANNEL,
gimp_param_spec_item_id ("channel",
"channel",
......@@ -102,20 +104,20 @@ register_channel_procs (Gimp *gimp)
gimp,
GIMP_TYPE_CHANNEL,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &channel_new_proc);
procedural_db_register (gimp, procedure);
/*
* channel_new_from_component
*/
procedural_db_init_proc (&channel_new_from_component_proc, 3, 1);
procedural_db_add_argument (&channel_new_from_component_proc,
procedure = procedural_db_init_proc (&channel_new_from_component_proc, 3, 1);
procedural_db_add_argument (procedure,
GIMP_PDB_IMAGE,
gimp_param_spec_image_id ("image",
"image",
"The image to which to add the channel",
gimp,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_new_from_component_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_enum ("component",
"component",
......@@ -123,7 +125,7 @@ register_channel_procs (Gimp *gimp)
GIMP_TYPE_CHANNEL_TYPE,
GIMP_RED_CHANNEL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_new_from_component_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_STRING,
gimp_param_spec_string ("name",
"name",
......@@ -131,7 +133,7 @@ register_channel_procs (Gimp *gimp)
FALSE, FALSE,
NULL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&channel_new_from_component_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_CHANNEL,
gimp_param_spec_item_id ("channel",
"channel",
......@@ -139,13 +141,13 @@ register_channel_procs (Gimp *gimp)
gimp,
GIMP_TYPE_CHANNEL,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &channel_new_from_component_proc);
procedural_db_register (gimp, procedure);
/*
* channel_copy
*/
procedural_db_init_proc (&channel_copy_proc, 1, 1);
procedural_db_add_argument (&channel_copy_proc,
procedure = procedural_db_init_proc (&channel_copy_proc, 1, 1);
procedural_db_add_argument (procedure,
GIMP_PDB_CHANNEL,
gimp_param_spec_item_id ("channel",
"channel",
......@@ -153,7 +155,7 @@ register_channel_procs (Gimp *gimp)
gimp,
GIMP_TYPE_CHANNEL,
GIMP_PARAM_READWRITE));
procedural_db_add_return_value (&channel_copy_proc,
procedural_db_add_return_value (procedure,
GIMP_PDB_CHANNEL,
gimp_param_spec_item_id ("channel-copy",
"channel copy",
......@@ -161,13 +163,13 @@ register_channel_procs (Gimp *gimp)
gimp,
GIMP_TYPE_CHANNEL,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &channel_copy_proc);
procedural_db_register (gimp, procedure);
/*
* channel_combine_masks
*/
procedural_db_init_proc (&channel_combine_masks_proc, 5, 0);
procedural_db_add_argument (&channel_combine_masks_proc,
procedure = procedural_db_init_proc (&channel_combine_masks_proc, 5, 0);
procedural_db_add_argument (procedure,
GIMP_PDB_CHANNEL,
gimp_param_spec_item_id ("channel1",
"channel1",
......@@ -175,7 +177,7 @@ register_channel_procs (Gimp *gimp)
gimp,
GIMP_TYPE_CHANNEL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_combine_masks_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_CHANNEL,
gimp_param_spec_item_id ("channel2",
"channel2",
......@@ -183,7 +185,7 @@ register_channel_procs (Gimp *gimp)
gimp,
GIMP_TYPE_CHANNEL,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_combine_masks_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_enum ("operation",
"operation",
......@@ -191,27 +193,27 @@ register_channel_procs (Gimp *gimp)
GIMP_TYPE_CHANNEL_OPS,
GIMP_CHANNEL_OP_ADD,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_combine_masks_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("offx",
"offx",
"x offset between upper left corner of channels: (second - first)",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_add_argument (&channel_combine_masks_proc,
procedural_db_add_argument (procedure,
GIMP_PDB_INT32,
g_param_spec_int ("offy",
"offy",
"y offset between upper left corner of channels: (second - first)",
G_MININT32, G_MAXINT32, 0,
GIMP_PARAM_READWRITE));
procedural_db_register (gimp, &channel_combine_masks_proc);