Commit 07e46abb authored by Michael Natterer's avatar Michael Natterer 😴

app, libgimp*: move enum GimpBucketFillMode to the core

The libgimp API using it is gone.
parent 368f2e59
......@@ -98,6 +98,37 @@ gimp_alignment_type_get_type (void)
return type;
}
GType
gimp_bucket_fill_mode_get_type (void)
{
static const GEnumValue values[] =
{
{ GIMP_BUCKET_FILL_FG, "GIMP_BUCKET_FILL_FG", "fg" },
{ GIMP_BUCKET_FILL_BG, "GIMP_BUCKET_FILL_BG", "bg" },
{ GIMP_BUCKET_FILL_PATTERN, "GIMP_BUCKET_FILL_PATTERN", "pattern" },
{ 0, NULL, NULL }
};
static const GimpEnumDesc descs[] =
{
{ GIMP_BUCKET_FILL_FG, NC_("bucket-fill-mode", "FG color fill"), NULL },
{ GIMP_BUCKET_FILL_BG, NC_("bucket-fill-mode", "BG color fill"), NULL },
{ GIMP_BUCKET_FILL_PATTERN, NC_("bucket-fill-mode", "Pattern fill"), NULL },
{ 0, NULL, NULL }
};
static GType type = 0;
if (G_UNLIKELY (! type))
{
type = g_enum_register_static ("GimpBucketFillMode", values);
gimp_type_set_translation_context (type, "bucket-fill-mode");
gimp_enum_set_value_descriptions (type, descs);
}
return type;
}
GType
gimp_channel_border_style_get_type (void)
{
......
......@@ -74,6 +74,26 @@ typedef enum /*< pdb-skip >*/
} GimpAlignmentType;
/**
* GimpBucketFillMode:
* @GIMP_BUCKET_FILL_FG: FG color fill
* @GIMP_BUCKET_FILL_BG: BG color fill
* @GIMP_BUCKET_FILL_PATTERN: Pattern fill
*
* Bucket fill modes.
*/
#define GIMP_TYPE_BUCKET_FILL_MODE (gimp_bucket_fill_mode_get_type ())
GType gimp_bucket_fill_mode_get_type (void) G_GNUC_CONST;
typedef enum
{
GIMP_BUCKET_FILL_FG, /*< desc="FG color fill" >*/
GIMP_BUCKET_FILL_BG, /*< desc="BG color fill" >*/
GIMP_BUCKET_FILL_PATTERN /*< desc="Pattern fill" >*/
} GimpBucketFillMode;
#define GIMP_TYPE_CHANNEL_BORDER_STYLE (gimp_channel_border_style_get_type ())
GType gimp_channel_border_style_get_type (void) G_GNUC_CONST;
......
......@@ -35,6 +35,18 @@ typedef enum
} GimpBrushApplicationMode;
#define GIMP_TYPE_BUCKET_FILL_MODE (gimp_bucket_fill_mode_get_type ())
GType gimp_bucket_fill_mode_get_type (void) G_GNUC_CONST;
typedef enum
{
GIMP_BUCKET_FILL_FG,
GIMP_BUCKET_FILL_BG,
GIMP_BUCKET_FILL_PATTERN
} GimpBucketFillMode;
#define GIMP_TYPE_CONVERT_DITHER_TYPE (gimp_convert_dither_type_get_type ())
GType gimp_convert_dither_type_get_type (void) G_GNUC_CONST;
......
......@@ -5,7 +5,6 @@ EXPORTS
gimp_base_init
gimp_blend_mode_get_type
gimp_brush_generated_shape_get_type
gimp_bucket_fill_mode_get_type
gimp_cache_directory
gimp_canonicalize_identifier
gimp_cap_style_get_type
......
......@@ -114,38 +114,6 @@ gimp_brush_generated_shape_get_type (void)
return type;
}
GType
gimp_bucket_fill_mode_get_type (void)
{
static const GEnumValue values[] =
{
{ GIMP_BUCKET_FILL_FG, "GIMP_BUCKET_FILL_FG", "fg" },
{ GIMP_BUCKET_FILL_BG, "GIMP_BUCKET_FILL_BG", "bg" },
{ GIMP_BUCKET_FILL_PATTERN, "GIMP_BUCKET_FILL_PATTERN", "pattern" },
{ 0, NULL, NULL }
};
static const GimpEnumDesc descs[] =
{
{ GIMP_BUCKET_FILL_FG, NC_("bucket-fill-mode", "FG color fill"), NULL },
{ GIMP_BUCKET_FILL_BG, NC_("bucket-fill-mode", "BG color fill"), NULL },
{ GIMP_BUCKET_FILL_PATTERN, NC_("bucket-fill-mode", "Pattern fill"), NULL },
{ 0, NULL, NULL }
};
static GType type = 0;
if (G_UNLIKELY (! type))
{
type = g_enum_register_static ("GimpBucketFillMode", values);
gimp_type_set_translation_domain (type, GETTEXT_PACKAGE "-libgimp");
gimp_type_set_translation_context (type, "bucket-fill-mode");
gimp_enum_set_value_descriptions (type, descs);
}
return type;
}
GType
gimp_cap_style_get_type (void)
{
......
......@@ -104,26 +104,6 @@ typedef enum
} GimpBrushGeneratedShape;
/**
* GimpBucketFillMode:
* @GIMP_BUCKET_FILL_FG: FG color fill
* @GIMP_BUCKET_FILL_BG: BG color fill
* @GIMP_BUCKET_FILL_PATTERN: Pattern fill
*
* Bucket fill modes.
*/
#define GIMP_TYPE_BUCKET_FILL_MODE (gimp_bucket_fill_mode_get_type ())
GType gimp_bucket_fill_mode_get_type (void) G_GNUC_CONST;
typedef enum
{
GIMP_BUCKET_FILL_FG, /*< desc="FG color fill" >*/
GIMP_BUCKET_FILL_BG, /*< desc="BG color fill" >*/
GIMP_BUCKET_FILL_PATTERN /*< desc="Pattern fill" >*/
} GimpBucketFillMode;
/**
* GimpCapStyle:
* @GIMP_CAP_BUTT: Butt
......
......@@ -64,15 +64,6 @@ package Gimp::CodeGen::enums;
GIMP_BRUSH_GENERATED_SQUARE => '1',
GIMP_BRUSH_GENERATED_DIAMOND => '2' }
},
GimpBucketFillMode =>
{ contig => 1,
header => 'libgimpbase/gimpbaseenums.h',
symbols => [ qw(GIMP_BUCKET_FILL_FG GIMP_BUCKET_FILL_BG
GIMP_BUCKET_FILL_PATTERN) ],
mapping => { GIMP_BUCKET_FILL_FG => '0',
GIMP_BUCKET_FILL_BG => '1',
GIMP_BUCKET_FILL_PATTERN => '2' }
},
GimpCapStyle =>
{ contig => 1,
header => 'libgimpbase/gimpbaseenums.h',
......@@ -852,6 +843,15 @@ package Gimp::CodeGen::enums;
GIMP_LAYER_MODE_SPLIT => '60',
GIMP_LAYER_MODE_PASS_THROUGH => '61' }
},
GimpBucketFillMode =>
{ contig => 1,
header => 'core/core-enums.h',
symbols => [ qw(GIMP_BUCKET_FILL_FG GIMP_BUCKET_FILL_BG
GIMP_BUCKET_FILL_PATTERN) ],
mapping => { GIMP_BUCKET_FILL_FG => '0',
GIMP_BUCKET_FILL_BG => '1',
GIMP_BUCKET_FILL_PATTERN => '2' }
},
GimpConvertDitherType =>
{ contig => 1,
header => 'core/core-enums.h',
......
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