[gimp] app, libgimpbase: move enum GimpBucketFillArea to the core
- From: Michael Natterer <mitch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gimp] app, libgimpbase: move enum GimpBucketFillArea to the core
- Date: Wed, 2 Jan 2019 14:52:57 +0000 (UTC)
commit 368f2e596af0fa84d7a107615b711321f2fabee9
Author: Michael Natterer <mitch gimp org>
Date: Wed Jan 2 15:47:31 2019 +0100
app, libgimpbase: move enum GimpBucketFillArea to the core
The whole bucket fill specific enum stuff is on its way out, so let's
keep this one out of libgimp for now until we decide how to present
line art filling in the PDB.
app/tools/tools-enums.c | 31 +++++++++++++++++++++++++++++++
app/tools/tools-enums.h | 20 ++++++++++++++++++++
libgimp/gimpenums.c.tail | 2 --
libgimpbase/gimpbase.def | 1 -
libgimpbase/gimpbaseenums.c | 32 --------------------------------
libgimpbase/gimpbaseenums.h | 20 --------------------
pdb/enums.pl | 10 ----------
7 files changed, 51 insertions(+), 65 deletions(-)
---
diff --git a/app/tools/tools-enums.c b/app/tools/tools-enums.c
index 9ac946711c..1ff1e9387a 100644
--- a/app/tools/tools-enums.c
+++ b/app/tools/tools-enums.c
@@ -9,6 +9,37 @@
#include "gimp-intl.h"
/* enumerations from "tools-enums.h" */
+GType
+gimp_bucket_fill_area_get_type (void)
+{
+ static const GEnumValue values[] =
+ {
+ { GIMP_BUCKET_FILL_SELECTION, "GIMP_BUCKET_FILL_SELECTION", "selection" },
+ { GIMP_BUCKET_FILL_SIMILAR_COLORS, "GIMP_BUCKET_FILL_SIMILAR_COLORS", "similar-colors" },
+ { GIMP_BUCKET_FILL_LINE_ART, "GIMP_BUCKET_FILL_LINE_ART", "line-art" },
+ { 0, NULL, NULL }
+ };
+
+ static const GimpEnumDesc descs[] =
+ {
+ { GIMP_BUCKET_FILL_SELECTION, NC_("bucket-fill-area", "Fill whole selection"), NULL },
+ { GIMP_BUCKET_FILL_SIMILAR_COLORS, NC_("bucket-fill-area", "Fill similar colors"), NULL },
+ { GIMP_BUCKET_FILL_LINE_ART, NC_("bucket-fill-area", "Fill by line art detection"), NULL },
+ { 0, NULL, NULL }
+ };
+
+ static GType type = 0;
+
+ if (G_UNLIKELY (! type))
+ {
+ type = g_enum_register_static ("GimpBucketFillArea", values);
+ gimp_type_set_translation_context (type, "bucket-fill-area");
+ gimp_enum_set_value_descriptions (type, descs);
+ }
+
+ return type;
+}
+
GType
gimp_rect_select_mode_get_type (void)
{
diff --git a/app/tools/tools-enums.h b/app/tools/tools-enums.h
index acbe05915a..592c17bd7c 100644
--- a/app/tools/tools-enums.h
+++ b/app/tools/tools-enums.h
@@ -23,6 +23,26 @@
* these enums are registered with the type system
*/
+/**
+ * GimpBucketFillArea:
+ * @GIMP_BUCKET_FILL_SELECTION: Fill whole selection
+ * @GIMP_BUCKET_FILL_SIMILAR_COLORS: Fill similar colors
+ * @GIMP_BUCKET_FILL_LINE_ART: Fill by line art detection
+ *
+ * Bucket fill area.
+ */
+#define GIMP_TYPE_BUCKET_FILL_AREA (gimp_bucket_fill_area_get_type ())
+
+GType gimp_bucket_fill_area_get_type (void) G_GNUC_CONST;
+
+typedef enum
+{
+ GIMP_BUCKET_FILL_SELECTION, /*< desc="Fill whole selection" >*/
+ GIMP_BUCKET_FILL_SIMILAR_COLORS, /*< desc="Fill similar colors" >*/
+ GIMP_BUCKET_FILL_LINE_ART /*< desc="Fill by line art detection" >*/
+} GimpBucketFillArea;
+
+
#define GIMP_TYPE_RECT_SELECT_MODE (gimp_rect_select_mode_get_type ())
GType gimp_rect_select_mode_get_type (void) G_GNUC_CONST;
diff --git a/libgimp/gimpenums.c.tail b/libgimp/gimpenums.c.tail
index aa86a56b61..e33a9fdbef 100644
--- a/libgimp/gimpenums.c.tail
+++ b/libgimp/gimpenums.c.tail
@@ -8,7 +8,6 @@ static const GimpGetTypeFunc get_type_funcs[] =
gimp_blend_mode_get_type,
gimp_brush_application_mode_get_type,
gimp_brush_generated_shape_get_type,
- gimp_bucket_fill_area_get_type,
gimp_bucket_fill_mode_get_type,
gimp_cap_style_get_type,
gimp_channel_ops_get_type,
@@ -76,7 +75,6 @@ static const gchar * const type_names[] =
"GimpBlendMode",
"GimpBrushApplicationMode",
"GimpBrushGeneratedShape",
- "GimpBucketFillArea",
"GimpBucketFillMode",
"GimpCapStyle",
"GimpChannelOps",
diff --git a/libgimpbase/gimpbase.def b/libgimpbase/gimpbase.def
index bfb0209a6f..42aacd3156 100644
--- a/libgimpbase/gimpbase.def
+++ b/libgimpbase/gimpbase.def
@@ -5,7 +5,6 @@ EXPORTS
gimp_base_init
gimp_blend_mode_get_type
gimp_brush_generated_shape_get_type
- gimp_bucket_fill_area_get_type
gimp_bucket_fill_mode_get_type
gimp_cache_directory
gimp_canonicalize_identifier
diff --git a/libgimpbase/gimpbaseenums.c b/libgimpbase/gimpbaseenums.c
index 47620a53eb..d7af905575 100644
--- a/libgimpbase/gimpbaseenums.c
+++ b/libgimpbase/gimpbaseenums.c
@@ -114,38 +114,6 @@ gimp_brush_generated_shape_get_type (void)
return type;
}
-GType
-gimp_bucket_fill_area_get_type (void)
-{
- static const GEnumValue values[] =
- {
- { GIMP_BUCKET_FILL_SELECTION, "GIMP_BUCKET_FILL_SELECTION", "selection" },
- { GIMP_BUCKET_FILL_SIMILAR_COLORS, "GIMP_BUCKET_FILL_SIMILAR_COLORS", "similar-colors" },
- { GIMP_BUCKET_FILL_LINE_ART, "GIMP_BUCKET_FILL_LINE_ART", "line-art" },
- { 0, NULL, NULL }
- };
-
- static const GimpEnumDesc descs[] =
- {
- { GIMP_BUCKET_FILL_SELECTION, NC_("bucket-fill-area", "Fill whole selection"), NULL },
- { GIMP_BUCKET_FILL_SIMILAR_COLORS, NC_("bucket-fill-area", "Fill similar colors"), NULL },
- { GIMP_BUCKET_FILL_LINE_ART, NC_("bucket-fill-area", "Fill by line art detection"), NULL },
- { 0, NULL, NULL }
- };
-
- static GType type = 0;
-
- if (G_UNLIKELY (! type))
- {
- type = g_enum_register_static ("GimpBucketFillArea", values);
- gimp_type_set_translation_domain (type, GETTEXT_PACKAGE "-libgimp");
- gimp_type_set_translation_context (type, "bucket-fill-area");
- gimp_enum_set_value_descriptions (type, descs);
- }
-
- return type;
-}
-
GType
gimp_bucket_fill_mode_get_type (void)
{
diff --git a/libgimpbase/gimpbaseenums.h b/libgimpbase/gimpbaseenums.h
index 274f746d3f..181049b20f 100644
--- a/libgimpbase/gimpbaseenums.h
+++ b/libgimpbase/gimpbaseenums.h
@@ -104,26 +104,6 @@ typedef enum
} GimpBrushGeneratedShape;
-/**
- * GimpBucketFillArea:
- * @GIMP_BUCKET_FILL_SELECTION: Fill whole selection
- * @GIMP_BUCKET_FILL_SIMILAR_COLORS: Fill similar colors
- * @GIMP_BUCKET_FILL_LINE_ART: Fill by line art detection
- *
- * Bucket fill area.
- */
-#define GIMP_TYPE_BUCKET_FILL_AREA (gimp_bucket_fill_area_get_type ())
-
-GType gimp_bucket_fill_area_get_type (void) G_GNUC_CONST;
-
-typedef enum
-{
- GIMP_BUCKET_FILL_SELECTION, /*< desc="Fill whole selection" >*/
- GIMP_BUCKET_FILL_SIMILAR_COLORS, /*< desc="Fill similar colors" >*/
- GIMP_BUCKET_FILL_LINE_ART /*< desc="Fill by line art detection" >*/
-} GimpBucketFillArea;
-
-
/**
* GimpBucketFillMode:
* @GIMP_BUCKET_FILL_FG: FG color fill
diff --git a/pdb/enums.pl b/pdb/enums.pl
index 105a16c7f0..06dfd46571 100644
--- a/pdb/enums.pl
+++ b/pdb/enums.pl
@@ -64,16 +64,6 @@ package Gimp::CodeGen::enums;
GIMP_BRUSH_GENERATED_SQUARE => '1',
GIMP_BRUSH_GENERATED_DIAMOND => '2' }
},
- GimpBucketFillArea =>
- { contig => 1,
- header => 'libgimpbase/gimpbaseenums.h',
- symbols => [ qw(GIMP_BUCKET_FILL_SELECTION
- GIMP_BUCKET_FILL_SIMILAR_COLORS
- GIMP_BUCKET_FILL_LINE_ART) ],
- mapping => { GIMP_BUCKET_FILL_SELECTION => '0',
- GIMP_BUCKET_FILL_SIMILAR_COLORS => '1',
- GIMP_BUCKET_FILL_LINE_ART => '2' }
- },
GimpBucketFillMode =>
{ contig => 1,
header => 'libgimpbase/gimpbaseenums.h',
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]