2007-12-11 01:54:41 -08:00
|
|
|
/* GIMP - The GNU Image Manipulation Program
|
|
|
|
|
* Copyright (C) 1995-2003 Spencer Kimball and Peter Mattis
|
|
|
|
|
*
|
2009-01-17 14:28:01 -08:00
|
|
|
* This program is free software: you can redistribute it and/or modify
|
2007-12-11 01:54:41 -08:00
|
|
|
* it under the terms of the GNU General Public License as published by
|
2009-01-17 14:28:01 -08:00
|
|
|
* the Free Software Foundation; either version 3 of the License, or
|
2007-12-11 01:54:41 -08:00
|
|
|
* (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
|
2018-07-11 14:47:19 -07:00
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
2007-12-11 01:54:41 -08:00
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
#ifndef __GIMP_PDB_UTILS_H__
|
|
|
|
|
#define __GIMP_PDB_UTILS_H__
|
|
|
|
|
|
|
|
|
|
|
2008-04-03 23:57:42 -07:00
|
|
|
GimpBrush * gimp_pdb_get_brush (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
app, pdb: prevent custom gradient from being renamed
Make internal data objects non-renamable, even if they're writable,
through gimp_data_is_name_editable(). Currently, the only such
object is the custom gradient.
Prevent changing the name of non-renamable data by making the name
entry of GimpDataEditor non-editable whenever
gimp_viewable_is_name_editable() is FALSE, even if the data is
otherwise editable.
Prevent the vairous PDB -rename() functions from renaming non-
renamable data, by adding a GimpPDBDataAccess flags type,
specifying the desired access mode for the data -- any combination
of READ, WRITE, and RENAME -- and replacing the 'writable'
parameter of the gimp_pdb_get_foo() functions with an 'access'
parameter. Change the various .pdb files to use READ where they'd
used FALSE, and WRITE where they'd used TRUE; use RENAME, isntead
of WRITE, in the -rename() functions.
2017-10-30 14:06:31 -07:00
|
|
|
GimpPDBDataAccess access,
|
2008-04-03 23:57:42 -07:00
|
|
|
GError **error);
|
|
|
|
|
GimpBrush * gimp_pdb_get_generated_brush (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
app, pdb: prevent custom gradient from being renamed
Make internal data objects non-renamable, even if they're writable,
through gimp_data_is_name_editable(). Currently, the only such
object is the custom gradient.
Prevent changing the name of non-renamable data by making the name
entry of GimpDataEditor non-editable whenever
gimp_viewable_is_name_editable() is FALSE, even if the data is
otherwise editable.
Prevent the vairous PDB -rename() functions from renaming non-
renamable data, by adding a GimpPDBDataAccess flags type,
specifying the desired access mode for the data -- any combination
of READ, WRITE, and RENAME -- and replacing the 'writable'
parameter of the gimp_pdb_get_foo() functions with an 'access'
parameter. Change the various .pdb files to use READ where they'd
used FALSE, and WRITE where they'd used TRUE; use RENAME, isntead
of WRITE, in the -rename() functions.
2017-10-30 14:06:31 -07:00
|
|
|
GimpPDBDataAccess access,
|
2008-04-03 23:57:42 -07:00
|
|
|
GError **error);
|
2011-10-31 13:07:08 -07:00
|
|
|
GimpDynamics * gimp_pdb_get_dynamics (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
app, pdb: prevent custom gradient from being renamed
Make internal data objects non-renamable, even if they're writable,
through gimp_data_is_name_editable(). Currently, the only such
object is the custom gradient.
Prevent changing the name of non-renamable data by making the name
entry of GimpDataEditor non-editable whenever
gimp_viewable_is_name_editable() is FALSE, even if the data is
otherwise editable.
Prevent the vairous PDB -rename() functions from renaming non-
renamable data, by adding a GimpPDBDataAccess flags type,
specifying the desired access mode for the data -- any combination
of READ, WRITE, and RENAME -- and replacing the 'writable'
parameter of the gimp_pdb_get_foo() functions with an 'access'
parameter. Change the various .pdb files to use READ where they'd
used FALSE, and WRITE where they'd used TRUE; use RENAME, isntead
of WRITE, in the -rename() functions.
2017-10-30 14:06:31 -07:00
|
|
|
GimpPDBDataAccess access,
|
2011-10-31 13:07:08 -07:00
|
|
|
GError **error);
|
2016-01-02 04:40:38 -08:00
|
|
|
GimpMybrush * gimp_pdb_get_mybrush (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
app, pdb: prevent custom gradient from being renamed
Make internal data objects non-renamable, even if they're writable,
through gimp_data_is_name_editable(). Currently, the only such
object is the custom gradient.
Prevent changing the name of non-renamable data by making the name
entry of GimpDataEditor non-editable whenever
gimp_viewable_is_name_editable() is FALSE, even if the data is
otherwise editable.
Prevent the vairous PDB -rename() functions from renaming non-
renamable data, by adding a GimpPDBDataAccess flags type,
specifying the desired access mode for the data -- any combination
of READ, WRITE, and RENAME -- and replacing the 'writable'
parameter of the gimp_pdb_get_foo() functions with an 'access'
parameter. Change the various .pdb files to use READ where they'd
used FALSE, and WRITE where they'd used TRUE; use RENAME, isntead
of WRITE, in the -rename() functions.
2017-10-30 14:06:31 -07:00
|
|
|
GimpPDBDataAccess access,
|
2016-01-02 04:40:38 -08:00
|
|
|
GError **error);
|
2008-04-03 23:57:42 -07:00
|
|
|
GimpPattern * gimp_pdb_get_pattern (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
|
|
|
|
GError **error);
|
|
|
|
|
GimpGradient * gimp_pdb_get_gradient (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
app, pdb: prevent custom gradient from being renamed
Make internal data objects non-renamable, even if they're writable,
through gimp_data_is_name_editable(). Currently, the only such
object is the custom gradient.
Prevent changing the name of non-renamable data by making the name
entry of GimpDataEditor non-editable whenever
gimp_viewable_is_name_editable() is FALSE, even if the data is
otherwise editable.
Prevent the vairous PDB -rename() functions from renaming non-
renamable data, by adding a GimpPDBDataAccess flags type,
specifying the desired access mode for the data -- any combination
of READ, WRITE, and RENAME -- and replacing the 'writable'
parameter of the gimp_pdb_get_foo() functions with an 'access'
parameter. Change the various .pdb files to use READ where they'd
used FALSE, and WRITE where they'd used TRUE; use RENAME, isntead
of WRITE, in the -rename() functions.
2017-10-30 14:06:31 -07:00
|
|
|
GimpPDBDataAccess access,
|
2008-04-03 23:57:42 -07:00
|
|
|
GError **error);
|
|
|
|
|
GimpPalette * gimp_pdb_get_palette (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
app, pdb: prevent custom gradient from being renamed
Make internal data objects non-renamable, even if they're writable,
through gimp_data_is_name_editable(). Currently, the only such
object is the custom gradient.
Prevent changing the name of non-renamable data by making the name
entry of GimpDataEditor non-editable whenever
gimp_viewable_is_name_editable() is FALSE, even if the data is
otherwise editable.
Prevent the vairous PDB -rename() functions from renaming non-
renamable data, by adding a GimpPDBDataAccess flags type,
specifying the desired access mode for the data -- any combination
of READ, WRITE, and RENAME -- and replacing the 'writable'
parameter of the gimp_pdb_get_foo() functions with an 'access'
parameter. Change the various .pdb files to use READ where they'd
used FALSE, and WRITE where they'd used TRUE; use RENAME, isntead
of WRITE, in the -rename() functions.
2017-10-30 14:06:31 -07:00
|
|
|
GimpPDBDataAccess access,
|
2008-04-03 23:57:42 -07:00
|
|
|
GError **error);
|
|
|
|
|
GimpFont * gimp_pdb_get_font (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
|
|
|
|
GError **error);
|
|
|
|
|
GimpBuffer * gimp_pdb_get_buffer (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
|
|
|
|
GError **error);
|
|
|
|
|
GimpPaintInfo * gimp_pdb_get_paint_info (Gimp *gimp,
|
|
|
|
|
const gchar *name,
|
|
|
|
|
GError **error);
|
2007-12-11 01:54:41 -08:00
|
|
|
|
2008-04-03 23:57:42 -07:00
|
|
|
gboolean gimp_pdb_item_is_attached (GimpItem *item,
|
2010-07-08 12:00:53 -07:00
|
|
|
GimpImage *image,
|
2012-11-08 11:46:18 -08:00
|
|
|
GimpPDBItemModify modify,
|
2008-04-03 23:57:42 -07:00
|
|
|
GError **error);
|
2010-07-23 13:08:28 -07:00
|
|
|
gboolean gimp_pdb_item_is_in_tree (GimpItem *item,
|
|
|
|
|
GimpImage *image,
|
2012-11-08 11:46:18 -08:00
|
|
|
GimpPDBItemModify modify,
|
2010-07-23 13:08:28 -07:00
|
|
|
GError **error);
|
2010-08-31 08:07:27 -07:00
|
|
|
gboolean gimp_pdb_item_is_in_same_tree (GimpItem *item,
|
|
|
|
|
GimpItem *item2,
|
|
|
|
|
GimpImage *image,
|
|
|
|
|
GError **error);
|
|
|
|
|
gboolean gimp_pdb_item_is_not_ancestor (GimpItem *item,
|
|
|
|
|
GimpItem *not_descendant,
|
|
|
|
|
GError **error);
|
2008-04-04 00:21:27 -07:00
|
|
|
gboolean gimp_pdb_item_is_floating (GimpItem *item,
|
2008-09-17 04:41:54 -07:00
|
|
|
GimpImage *dest_image,
|
2008-04-04 00:21:27 -07:00
|
|
|
GError **error);
|
2018-04-20 14:32:07 -07:00
|
|
|
gboolean gimp_pdb_item_is_modifiable (GimpItem *item,
|
2012-11-08 11:46:18 -08:00
|
|
|
GimpPDBItemModify modify,
|
2009-08-20 09:50:55 -07:00
|
|
|
GError **error);
|
2010-08-31 08:07:27 -07:00
|
|
|
gboolean gimp_pdb_item_is_group (GimpItem *item,
|
|
|
|
|
GError **error);
|
2009-08-28 11:15:13 -07:00
|
|
|
gboolean gimp_pdb_item_is_not_group (GimpItem *item,
|
|
|
|
|
GError **error);
|
2009-08-20 09:50:55 -07:00
|
|
|
|
2008-04-03 23:57:42 -07:00
|
|
|
gboolean gimp_pdb_layer_is_text_layer (GimpLayer *layer,
|
2012-11-08 11:46:18 -08:00
|
|
|
GimpPDBItemModify modify,
|
2008-04-03 23:57:42 -07:00
|
|
|
GError **error);
|
2009-08-20 09:50:55 -07:00
|
|
|
|
2008-04-03 23:57:42 -07:00
|
|
|
gboolean gimp_pdb_image_is_base_type (GimpImage *image,
|
|
|
|
|
GimpImageBaseType type,
|
|
|
|
|
GError **error);
|
|
|
|
|
gboolean gimp_pdb_image_is_not_base_type (GimpImage *image,
|
|
|
|
|
GimpImageBaseType type,
|
|
|
|
|
GError **error);
|
2008-02-04 09:12:25 -08:00
|
|
|
|
2012-04-25 11:16:29 -07:00
|
|
|
gboolean gimp_pdb_image_is_precision (GimpImage *image,
|
|
|
|
|
GimpPrecision precision,
|
|
|
|
|
GError **error);
|
|
|
|
|
gboolean gimp_pdb_image_is_not_precision (GimpImage *image,
|
2012-04-25 08:39:49 -07:00
|
|
|
GimpPrecision precision,
|
|
|
|
|
GError **error);
|
|
|
|
|
|
2014-07-10 11:24:10 -07:00
|
|
|
GimpGuide * gimp_pdb_image_get_guide (GimpImage *image,
|
|
|
|
|
gint guide_ID,
|
|
|
|
|
GError **error);
|
2016-01-04 12:13:48 -08:00
|
|
|
GimpSamplePoint *
|
|
|
|
|
gimp_pdb_image_get_sample_point (GimpImage *image,
|
|
|
|
|
gint sample_point_ID,
|
|
|
|
|
GError **error);
|
2014-07-10 11:24:10 -07:00
|
|
|
|
2008-04-03 23:57:42 -07:00
|
|
|
GimpStroke * gimp_pdb_get_vectors_stroke (GimpVectors *vectors,
|
|
|
|
|
gint stroke_ID,
|
2012-11-08 11:46:18 -08:00
|
|
|
GimpPDBItemModify modify,
|
2008-04-03 23:57:42 -07:00
|
|
|
GError **error);
|
2008-03-06 10:39:07 -08:00
|
|
|
|
2007-12-11 01:54:41 -08:00
|
|
|
|
|
|
|
|
#endif /* __GIMP_PDB_UTILS_H__ */
|