Commit 682ab691 authored by Michael Natterer's avatar Michael Natterer 😴

Revert "pdb: move PDB generation and sources to toplevel/pdb"

This reverts commit 3b639b1d.
parent 6dfb2ef5
...@@ -116,7 +116,7 @@ sources. All those files have a short notice about being generated ...@@ -116,7 +116,7 @@ sources. All those files have a short notice about being generated
somewhere at the top. Among them are the files ending in pdb.[ch] in somewhere at the top. Among them are the files ending in pdb.[ch] in
the libgimp directory and the files ending in cmds.c in the app/pdb the libgimp directory and the files ending in cmds.c in the app/pdb
subdirectory. Those are generated from the respective .pdb files in subdirectory. Those are generated from the respective .pdb files in
pdb/groups. tools/pdbgen/pdb.
Hackordnung Hackordnung
......
...@@ -2,10 +2,6 @@ ...@@ -2,10 +2,6 @@
ACLOCAL_AMFLAGS = -I m4macros ${ACLOCAL_FLAGS} ACLOCAL_AMFLAGS = -I m4macros ${ACLOCAL_FLAGS}
if WITH_PDBGEN
PDB = pdb
endif
SUBDIRS = \ SUBDIRS = \
m4macros \ m4macros \
cursors \ cursors \
...@@ -21,7 +17,6 @@ SUBDIRS = \ ...@@ -21,7 +17,6 @@ SUBDIRS = \
menus \ menus \
libgimpbase \ libgimpbase \
tools \ tools \
$(PDB) \
icons \ icons \
libgimpcolor \ libgimpcolor \
libgimpmath \ libgimpmath \
......
...@@ -118,7 +118,7 @@ app_libs_init (GOptionContext *context, ...@@ -118,7 +118,7 @@ app_libs_init (GOptionContext *context,
} }
#endif #endif
/* keep compat enum code in sync with pdb/enumcode.pl */ /* keep compat enum code in sync with tools/pdbgen/enumcode.pl */
quark = g_quark_from_static_string ("gimp-compat-enum"); quark = g_quark_from_static_string ("gimp-compat-enum");
g_type_set_qdata (GIMP_TYPE_CONVERT_DITHER_TYPE, quark, g_type_set_qdata (GIMP_TYPE_CONVERT_DITHER_TYPE, quark,
......
...@@ -20,7 +20,7 @@ ...@@ -20,7 +20,7 @@
#if 0 #if 0
This file is parsed by two scripts, enumgen.pl in pdb, This file is parsed by two scripts, enumgen.pl in tools/pdbgen,
and gimp-mkenums. All enums that are not marked with and gimp-mkenums. All enums that are not marked with
/*< pdb-skip >*/ are exported to libgimp and the PDB. Enums that are /*< pdb-skip >*/ are exported to libgimp and the PDB. Enums that are
not marked with /*< skip >*/ are registered with the GType system. not marked with /*< skip >*/ are registered with the GType system.
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
#define __PAINT_ENUMS_H__ #define __PAINT_ENUMS_H__
#if 0 #if 0
This file is parsed by two scripts, enumgen.pl in pdb, This file is parsed by two scripts, enumgen.pl in tools/pdbgen,
and gimp-mkenums. All enums that are not marked with and gimp-mkenums. All enums that are not marked with
/*< pdb-skip >*/ are exported to libgimp and the PDB. Enums that are /*< pdb-skip >*/ are exported to libgimp and the PDB. Enums that are
not marked with /*< skip >*/ are registered with the GType system. not marked with /*< skip >*/ are registered with the GType system.
......
...@@ -3,5 +3,5 @@ Gimp functions. ...@@ -3,5 +3,5 @@ Gimp functions.
THESE FILES ARE AUTOGENERATED AND CHANGES HERE ARE USELESS! THESE FILES ARE AUTOGENERATED AND CHANGES HERE ARE USELESS!
If you need to change the code please have a look in ../../pdb/groups. If you need to change the code please have a look in ../../tools/pdbgen/pdb.
...@@ -2480,7 +2480,7 @@ _______EOF ...@@ -2480,7 +2480,7 @@ _______EOF
AC_CONFIG_FILES([ AC_CONFIG_FILES([
INSTALL INSTALL
tools/Makefile tools/Makefile
pdb/Makefile tools/pdbgen/Makefile
libgimp/Makefile libgimp/Makefile
libgimpbase/Makefile libgimpbase/Makefile
libgimpconfig/Makefile libgimpconfig/Makefile
......
#!/usr/bin/perl -w #!/usr/bin/perl -w
use lib '../../pdb'; use lib '../../tools/pdbgen';
require 'util.pl'; require 'util.pl';
......
...@@ -2,6 +2,12 @@ ...@@ -2,6 +2,12 @@
libgimpbase = $(top_builddir)/libgimpbase/libgimpbase-$(GIMP_API_VERSION).la libgimpbase = $(top_builddir)/libgimpbase/libgimpbase-$(GIMP_API_VERSION).la
if WITH_PDBGEN
PDBGEN = pdbgen
endif
SUBDIRS = $(PDBGEN)
if OS_WIN32 if OS_WIN32
bin_PROGRAMS = \ bin_PROGRAMS = \
...@@ -88,3 +94,4 @@ EXTRA_DIST = \ ...@@ -88,3 +94,4 @@ EXTRA_DIST = \
gimp-mkenums \ gimp-mkenums \
gimppath2svg.py \ gimppath2svg.py \
invert-svg.c invert-svg.c
PDBGEN_BACKUP = 0 PDBGEN_BACKUP = 0
PDBGEN_GROUPS = PDBGEN_GROUPS =
pdb_groups = \ pdb_sources = \
groups/brush.pdb \ pdb/brush.pdb \
groups/brush_select.pdb \ pdb/brush_select.pdb \
groups/brushes.pdb \ pdb/brushes.pdb \
groups/buffer.pdb \ pdb/buffer.pdb \
groups/channel.pdb \ pdb/channel.pdb \
groups/color.pdb \ pdb/color.pdb \
groups/context.pdb \ pdb/context.pdb \
groups/debug.pdb \ pdb/debug.pdb \
groups/display.pdb \ pdb/display.pdb \
groups/drawable.pdb \ pdb/drawable.pdb \
groups/drawable_color.pdb \ pdb/drawable_color.pdb \
groups/drawable_transform.pdb \ pdb/drawable_transform.pdb \
groups/dynamics.pdb \ pdb/dynamics.pdb \
groups/edit.pdb \ pdb/edit.pdb \
groups/fileops.pdb \ pdb/fileops.pdb \
groups/floating_sel.pdb \ pdb/floating_sel.pdb \
groups/font_select.pdb \ pdb/font_select.pdb \
groups/fonts.pdb \ pdb/fonts.pdb \
groups/gimp.pdb \ pdb/gimp.pdb \
groups/gimprc.pdb \ pdb/gimprc.pdb \
groups/gradient.pdb \ pdb/gradient.pdb \
groups/gradient_select.pdb \ pdb/gradient_select.pdb \
groups/gradients.pdb \ pdb/gradients.pdb \
groups/help.pdb \ pdb/help.pdb \
groups/image.pdb \ pdb/image.pdb \
groups/image_color_profile.pdb \ pdb/image_color_profile.pdb \
groups/image_convert.pdb \ pdb/image_convert.pdb \
groups/image_grid.pdb \ pdb/image_grid.pdb \
groups/image_guides.pdb \ pdb/image_guides.pdb \
groups/image_sample_points.pdb \ pdb/image_sample_points.pdb \
groups/image_select.pdb \ pdb/image_select.pdb \
groups/image_transform.pdb \ pdb/image_transform.pdb \
groups/image_undo.pdb \ pdb/image_undo.pdb \
groups/item.pdb \ pdb/item.pdb \
groups/item_transform.pdb \ pdb/item_transform.pdb \
groups/layer.pdb \ pdb/layer.pdb \
groups/message.pdb \ pdb/message.pdb \
groups/paint_tools.pdb \ pdb/paint_tools.pdb \
groups/palette.pdb \ pdb/palette.pdb \
groups/palette_select.pdb \ pdb/palette_select.pdb \
groups/palettes.pdb \ pdb/palettes.pdb \
groups/paths.pdb \ pdb/paths.pdb \
groups/pattern.pdb \ pdb/pattern.pdb \
groups/pattern_select.pdb \ pdb/pattern_select.pdb \
groups/patterns.pdb \ pdb/patterns.pdb \
groups/plug_in.pdb \ pdb/plug_in.pdb \
groups/plug_in_compat.pdb \ pdb/plug_in_compat.pdb \
groups/procedural_db.pdb \ pdb/procedural_db.pdb \
groups/progress.pdb \ pdb/progress.pdb \
groups/selection.pdb \ pdb/selection.pdb \
groups/selection_tools.pdb \ pdb/selection_tools.pdb \
groups/text_layer.pdb \ pdb/text_layer.pdb \
groups/text_tool.pdb \ pdb/text_tool.pdb \
groups/transform_tools.pdb \ pdb/transform_tools.pdb \
groups/unit.pdb \ pdb/unit.pdb \
groups/vectors.pdb pdb/vectors.pdb
EXTRA_DIST = \ EXTRA_DIST = \
README \ README \
...@@ -72,14 +72,14 @@ EXTRA_DIST = \ ...@@ -72,14 +72,14 @@ EXTRA_DIST = \
pdbgen.pl \ pdbgen.pl \
stddefs.pdb \ stddefs.pdb \
util.pl \ util.pl \
$(pdb_groups) $(pdb_sources)
enum_headers = \ enum_headers = \
../libgimpbase/gimpbaseenums.h \ ../../libgimpbase/gimpbaseenums.h \
../libgimpconfig/gimpconfigenums.h \ ../../libgimpconfig/gimpconfigenums.h \
../app/operations/operations-enums.h \ ../../app/operations/operations-enums.h \
../app/core/core-enums.h \ ../../app/core/core-enums.h \
../app/paint/paint-enums.h ../../app/paint/paint-enums.h
pdb_scripts = \ pdb_scripts = \
pdbgen.pl \ pdbgen.pl \
...@@ -125,8 +125,8 @@ stamp-groups: Makefile.am ...@@ -125,8 +125,8 @@ stamp-groups: Makefile.am
rootme=`pwd`; cd $(srcdir) \ rootme=`pwd`; cd $(srcdir) \
&& echo "# This file is autogenerated" > $$rootme/groups.pl.tmp \ && echo "# This file is autogenerated" > $$rootme/groups.pl.tmp \
&& echo "@groups = qw(" >> $$rootme/groups.pl.tmp \ && echo "@groups = qw(" >> $$rootme/groups.pl.tmp \
&& (for pdb in $(pdb_groups); do \ && (for pdb in $(pdb_sources); do \
group=`echo $$pdb | sed -e 's%groups/\([^.]*\)\..*%\1%'`; \ group=`echo $$pdb | sed -e 's%pdb/\([^.]*\)\..*%\1%'`; \
echo " $$group" >> $$rootme/groups.pl.tmp; \ echo " $$group" >> $$rootme/groups.pl.tmp; \
done) \ done) \
&& echo ");" >> $$rootme/groups.pl.tmp \ && echo ");" >> $$rootme/groups.pl.tmp \
...@@ -135,7 +135,7 @@ stamp-groups: Makefile.am ...@@ -135,7 +135,7 @@ stamp-groups: Makefile.am
&& rm $$rootme/groups.pl.tmp \ && rm $$rootme/groups.pl.tmp \
&& echo timestamp > $$rootme/stamp-groups && echo timestamp > $$rootme/stamp-groups
stamp-pdbgen: $(pdbgen_deps) $(pdb_scripts) $(pdb_groups) Makefile.am stamp-pdbgen: $(pdbgen_deps) $(pdb_scripts) $(pdb_sources) Makefile.am
rootme=`pwd`; \ rootme=`pwd`; \
destdir=`cd $(top_srcdir) && pwd`; export destdir; \ destdir=`cd $(top_srcdir) && pwd`; export destdir; \
builddir=`cd $(top_builddir) && pwd`; export builddir; \ builddir=`cd $(top_builddir) && pwd`; export builddir; \
......
...@@ -63,7 +63,7 @@ http://git.gnome.org/browse/gimp/tree/tools/pdbgen/pdb[tools/pdbgen/pdb]. ...@@ -63,7 +63,7 @@ http://git.gnome.org/browse/gimp/tree/tools/pdbgen/pdb[tools/pdbgen/pdb].
You can see many files with the .pdb suffix - these are special template You can see many files with the .pdb suffix - these are special template
files which include the actual source of the PDB functions. Let's take a files which include the actual source of the PDB functions. Let's take a
quick look at one of these - text_layer_get_text in quick look at one of these - text_layer_get_text in
http://git.gnome.org/browse/gimp/tree/pdb/groups/text_layer.pdb[pdb/groups/text_layer.pdb]. http://git.gnome.org/browse/gimp/tree/tools/pdbgen/pdb/text_layer.pdb[tools/pdbgen/pdb/text_layer.pdb].
[source,perl] [source,perl]
---- ----
...@@ -337,7 +337,7 @@ this can be done automatically for you if the desired enum is one of the ...@@ -337,7 +337,7 @@ this can be done automatically for you if the desired enum is one of the
enums which are already used by GIMP. enums which are already used by GIMP.
To make it clearer, let's take a look at +layer_get_mode+ in To make it clearer, let's take a look at +layer_get_mode+ in
http://git.gnome.org/browse/gimp/tree/pdb/groups/layer.pdb[pdb/groups/layer.pdb]: http://git.gnome.org/browse/gimp/tree/tools/pdbgen/pdb/layer.pdb[tools/pdbgen/pdb/layer.pdb]:
[source,perl] [source,perl]
---- ----
...@@ -388,7 +388,7 @@ function, and by that we can make sure it won't be called with values ...@@ -388,7 +388,7 @@ function, and by that we can make sure it won't be called with values
out of range (GIMP will make sure the values are inside the specified out of range (GIMP will make sure the values are inside the specified
range before it calls our function). To see an example, let's take look range before it calls our function). To see an example, let's take look
at the procedure image_new from at the procedure image_new from
http://git.gnome.org/browse/gimp/tree/pdb/groups/image.pdb[pdb/groups/image.pdb]: http://git.gnome.org/browse/gimp/tree/tools/pdbgen/pdb/image.pdb[tools/pdbgen/pdb/image.pdb]:
[source,perl] [source,perl]
---- ----
...@@ -435,7 +435,7 @@ function which receives an array. Array arguments are specified in a ...@@ -435,7 +435,7 @@ function which receives an array. Array arguments are specified in a
special way which is a bit different than the other arguments. To see special way which is a bit different than the other arguments. To see
how array arguments are specified, let's take a look at the +@outargs+ how array arguments are specified, let's take a look at the +@outargs+
of +vectors_stroke_get_points+ from of +vectors_stroke_get_points+ from
http://git.gnome.org/browse/gimp/tree/pdb/groups/vectors.pdb[pdb/groups/vectors.pdb]: http://git.gnome.org/browse/gimp/tree/tools/pdbgen/pdb/vectors.pdb[tools/pdbgen/pdb/vectors.pdb]:
[source,perl] [source,perl]
---- ----
......
This diff is collapsed.
# GIMP - The GNU Image Manipulation Program
# Copyright (C) 1995 Spencer Kimball and Peter Mattis
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# "Perlized" from C source by Manish Singh <yosh@gimp.org>
sub brushes_popup {
$blurb = 'Invokes the Gimp brush selection.';
$help = 'This procedure opens the brush selection dialog.';
&andy_pdb_misc('1998');
@inargs = (
{ name => 'brush_callback', type => 'string', non_empty => 1,
desc => 'The callback PDB proc to call when brush selection is
made' },
{ name => 'popup_title', type => 'string',
desc => 'Title of the brush selection dialog' },
{ name => 'initial_brush', type => 'string', null_ok => 1,
desc => 'The name of the brush to set as the first selected' },
{ name => 'opacity', type => '0 <= float <= 100',
desc => 'The initial opacity of the brush' },
{ name => 'spacing', type => 'int32 <= 1000',
desc => 'The initial spacing of the brush (if < 0 then use brush
default spacing)' },
{ name => 'paint_mode', type => 'enum GimpLayerMode',
default => 'GIMP_LAYER_MODE_NORMAL',
desc => 'The initial paint mode' }
);
%invoke = (
code => <<'CODE'
{
if (paint_mode == GIMP_LAYER_MODE_OVERLAY_LEGACY)
paint_mode = GIMP_LAYER_MODE_SOFTLIGHT_LEGACY;
if (gimp->no_interface ||
! gimp_pdb_lookup_procedure (gimp->pdb, brush_callback) ||
! gimp_pdb_dialog_new (gimp, context, progress,
gimp_data_factory_get_container (gimp->brush_factory),
popup_title, brush_callback, initial_brush,
"opacity", opacity / 100.0,
"paint-mode", paint_mode,
"spacing", spacing,
NULL))
success = FALSE;
}
CODE
);
}
sub brushes_close_popup {
$blurb = 'Close the brush selection dialog.';
$help = 'This procedure closes an opened brush selection dialog.';
&andy_pdb_misc('1998');
@inargs = (
{ name => 'brush_callback', type => 'string', non_empty => 1,
desc => 'The name of the callback registered for this pop-up' }
);
%invoke = (
code => <<'CODE'
{
if (gimp->no_interface ||
! gimp_pdb_lookup_procedure (gimp->pdb, brush_callback) ||
! gimp_pdb_dialog_close (gimp, gimp_data_factory_get_container (gimp->brush_factory),
brush_callback))
success = FALSE;
}
CODE
);
}
sub brushes_set_popup {
$blurb = 'Sets the current brush in a brush selection dialog.';
$help = $blurb;
&andy_pdb_misc('1998');
@inargs = (
{ name => 'brush_callback', type => 'string', non_empty => 1,
desc => 'The name of the callback registered for this pop-up' },
{ name => 'brush_name', type => 'string',
desc => 'The name of the brush to set as selected' },
{ name => 'opacity', type => '0 <= float <= 100',
desc => 'The initial opacity of the brush' },
{ name => 'spacing', type => 'int32 <= 1000',
desc => 'The initial spacing of the brush (if < 0 then use brush
default spacing)' },
{ name => 'paint_mode', type => 'enum GimpLayerMode',
default => 'GIMP_LAYER_MODE_NORMAL',
desc => 'The initial paint mode' }
);
%invoke = (
code => <<'CODE'
{
if (paint_mode == GIMP_LAYER_MODE_OVERLAY_LEGACY)
paint_mode = GIMP_LAYER_MODE_SOFTLIGHT_LEGACY;
if (gimp->no_interface ||
! gimp_pdb_lookup_procedure (gimp->pdb, brush_callback) ||
! gimp_pdb_dialog_set (gimp, gimp_data_factory_get_container (gimp->brush_factory),
brush_callback, brush_name,
"opacity", opacity / 100.0,
"paint-mode", paint_mode,
"spacing", spacing,
NULL))
success = FALSE;
}
CODE
);
}
@headers = qw("core/gimp.h"
"core/gimpdatafactory.h");
@procs = qw(brushes_popup
brushes_close_popup
brushes_set_popup);
%exports = (app => [@procs], lib => [@procs]);
$desc = 'Brush UI';
$doc_title = 'gimpbrushselect';
$doc_short_desc = 'Functions providing a brush selection dialog.';
$doc_long_desc = 'Functions providing a brush selection dialog.';
1;
# GIMP - The GNU Image Manipulation Program
# Copyright (C) 1995 Spencer Kimball and Peter Mattis
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <http://www.gnu.org/licenses/>.
# "Perlized" from C source by Manish Singh <yosh@gimp.org>
sub brushes_refresh {
$blurb = 'Refresh current brushes. This function always succeeds.';
$help = <<'HELP';
This procedure retrieves all brushes currently in the user's brush path
and updates the brush dialogs accordingly.
HELP
&seth_pdb_misc('1997');
%invoke = (
code => <<'CODE'
{
gimp_data_factory_data_refresh (gimp->brush_factory, context);
}
CODE
);
}
sub brushes_get_list {
$blurb = 'Retrieve a complete listing of the available brushes.';
$help = <<'HELP';
This procedure returns a complete listing of available GIMP
brushes. Each name returned can be used as input to the
gimp_context_set_brush() procedure.
HELP
&std_pdb_misc;
@inargs = (
{ name => 'filter', type => 'string', null_ok => 1,
desc => 'An optional regular expression used to filter the list' }
);
@outargs = (
{ name => 'brush_list', type => 'stringarray',
desc => 'The list of brush names',
array => { name => 'num_brushes',
desc => 'The number of brushes in the brush list' } }
);
%invoke = (
headers => [ qw("core/gimpcontainer-filter.h") ],
code => <<'CODE'
{
brush_list = gimp_container_get_filtered_name_array (gimp_data_factory_get_container (gimp->brush_factory),
filter, &num_brushes);
}
CODE
);
}
sub brushes_get_brush {
&std_pdb_deprecated ('gimp-context-get-brush');
@outargs = (
{ name => 'name', type => 'string',
desc => 'The brush name' },
{ name => 'width', type => 'int32',
desc => 'The brush width' },
{ name => 'height', type => 'int32',
desc => 'The brush height' },
{ name => 'spacing', type => '0 <= int32 <= 1000',
desc => 'The brush spacing' }
);
%invoke = (
code => <<'CODE'
{
GimpBrush *brush = gimp_context_get_brush (context);
if (brush)
{
name = g_strdup (gimp_object_get_name (brush));
width = gimp_brush_get_width (brush);
height = gimp_brush_get_height (brush);
spacing = gimp_brush_get_spacing (brush);
}
else
success = FALSE;
}
CODE
);
}
sub brushes_get_spacing {
&std_pdb_deprecated ('gimp-brush-get-spacing');
@outargs = (
{ name => 'spacing', type => '0 <= int32 <= 1000',
desc => 'The brush spacing' }
);
%invoke = (
code =><<'CODE'
{
GimpBrush *brush = gimp_context_get_brush (context);
if (brush)
spacing = gimp_brush_get_spacing (brush);
else
success = FALSE;
}
CODE
);
}
sub brushes_set_spacing {
&std_pdb_deprecated ('gimp-brush-set-spacing');
@inargs = (
{ name => 'spacing', type => '0 <= int32 <= 1000',
desc => 'The brush spacing' }
);
%invoke = (
code => <<'CODE'
{
gimp_brush_set_spacing (gimp_context_get_brush (context), spacing);
}
CODE
);
}
sub brushes_get_brush_data {
&std_pdb_deprecated ('gimp-brush-get-pixels');
@inargs = (
{ name => 'name', type => 'string', null_ok => 1,
desc => 'The brush name ("" means current active brush)' }
);
@outargs = (
{ name => 'actual_name', type => 'string',
desc => 'The brush name' },
{ name => 'opacity', type => '0 <= float <= 100',
desc => 'The brush opacity' },
{ name => 'spacing', type => '0 <= int32 <= 1000',
desc => 'The brush spacing' },
{ name => 'paint_mode', type => 'enum GimpLayerMode',
default => 'GIMP_LAYER_MODE_NORMAL',
desc => 'The paint mode' },
{ name => 'width', type => 'int32',
desc => 'The brush width' },
{ name => 'height', type => 'int32',
desc => 'The brush height' },
{ name => 'mask_data', type => 'int8array',
desc => 'The brush mask data',
array => { name => 'length',
desc => 'Length of brush mask data' } }
);
%invoke = (
code => <<'CODE'
{
GimpBrush *brush;
if (paint_mode == GIMP_LAYER_MODE_OVERLAY_LEGACY)
paint_mode = GIMP_LAYER_MODE_SOFTLIGHT_LEGACY;
if (name && strlen (name))
brush = gimp_pdb_get_brush (gimp, name, FALSE, error);
else
brush = gimp_context_get_brush (context);
if (brush)
{
GimpTempBuf *mask = gimp_brush_get_mask (brush);
actual_name = g_strdup (gimp_object_get_name (brush));
opacity = 1.0;
spacing = gimp_brush_get_spacing (brush);
paint_mode = 0;
width = gimp_brush_get_width (brush);
height = gimp_brush_get_height (brush);
length = gimp_temp_buf_get_data_size (mask);
mask_data = g_memdup (gimp_temp_buf_get_data (mask), length);
}
else
success = FALSE;
}
CODE
);
}
@headers = qw(<string.h>
"core/gimp.h"
"core/gimpbrush.h"
"core/gimpcontext.h"
"core/gimpdatafactory.h"
"core/gimptempbuf.h"
"gimppdb-utils.h");
@procs = qw(brushes_refresh
brushes_get_list
brushes_get_brush
brushes_get_spacing brushes_set_spacing