[gimp] */Makefile.am: add abbreviations to generated enum files



commit f7d6805ebb0b2a4fec50c33315235d4622e6e5fe
Author: Ell <ell_se yahoo com>
Date:   Wed Nov 29 16:27:59 2017 -0500

    */Makefile.am: add abbreviations to generated enum files
    
    Update the dprod production of generated enum files to include
    abbreviated value descriptions, as per the previous commits.
    
    Add a comment for translators above the abbreviated descriptions,
    specifying the full description they abbreviate.

 app/config/Makefile.am     |    2 +-
 app/core/Makefile.am       |    2 +-
 app/display/Makefile.am    |    2 +-
 app/gegl/Makefile.am       |    2 +-
 app/operations/Makefile.am |    2 +-
 app/paint/Makefile.am      |    2 +-
 app/plug-in/Makefile.am    |    2 +-
 app/text/Makefile.am       |    2 +-
 app/tools/Makefile.am      |    2 +-
 app/widgets/Makefile.am    |    2 +-
 libgimp/Makefile.am        |    2 +-
 libgimpbase/Makefile.am    |    4 ++--
 libgimpconfig/Makefile.am  |    2 +-
 libgimpwidgets/Makefile.am |    2 +-
 14 files changed, 15 insertions(+), 15 deletions(-)
---
diff --git a/app/config/Makefile.am b/app/config/Makefile.am
index daa949f..ecc9a20 100644
--- a/app/config/Makefile.am
+++ b/app/config/Makefile.am
@@ -145,7 +145,7 @@ xgen-cec: $(srcdir)/config-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/core/Makefile.am b/app/core/Makefile.am
index 8e87169..c3be33a 100644
--- a/app/core/Makefile.am
+++ b/app/core/Makefile.am
@@ -461,7 +461,7 @@ xgen-cec: $(srcdir)/core-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/display/Makefile.am b/app/display/Makefile.am
index 410e8b8..2851dcb 100644
--- a/app/display/Makefile.am
+++ b/app/display/Makefile.am
@@ -206,7 +206,7 @@ xgen-dec: $(srcdir)/display-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/gegl/Makefile.am b/app/gegl/Makefile.am
index 1643c8c..b62cc96 100644
--- a/app/gegl/Makefile.am
+++ b/app/gegl/Makefile.am
@@ -82,7 +82,7 @@ xgen-ggec: $(srcdir)/gimp-gegl-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/operations/Makefile.am b/app/operations/Makefile.am
index f76c73e..5c4ed02 100644
--- a/app/operations/Makefile.am
+++ b/app/operations/Makefile.am
@@ -117,7 +117,7 @@ xgen-oec: $(srcdir)/operations-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/paint/Makefile.am b/app/paint/Makefile.am
index cf67fd1..149edba 100644
--- a/app/paint/Makefile.am
+++ b/app/paint/Makefile.am
@@ -106,7 +106,7 @@ xgen-pec: $(srcdir)/paint-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/plug-in/Makefile.am b/app/plug-in/Makefile.am
index cde8260..852fdbb 100644
--- a/app/plug-in/Makefile.am
+++ b/app/plug-in/Makefile.am
@@ -89,7 +89,7 @@ xgen-pec: $(srcdir)/plug-in-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/text/Makefile.am b/app/text/Makefile.am
index f2fdd34..20bbf71 100644
--- a/app/text/Makefile.am
+++ b/app/text/Makefile.am
@@ -65,7 +65,7 @@ xgen-tec: $(srcdir)/text-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/tools/Makefile.am b/app/tools/Makefile.am
index fbda7b8..dfe640e 100644
--- a/app/tools/Makefile.am
+++ b/app/tools/Makefile.am
@@ -238,7 +238,7 @@ xgen-tec: $(srcdir)/tools-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/app/widgets/Makefile.am b/app/widgets/Makefile.am
index c672a3c..4ed2e74 100644
--- a/app/widgets/Makefile.am
+++ b/app/widgets/Makefile.am
@@ -464,7 +464,7 @@ xgen-wec: $(srcdir)/widgets-enums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/libgimp/Makefile.am b/libgimp/Makefile.am
index 9049944..2e71ba9 100644
--- a/libgimp/Makefile.am
+++ b/libgimp/Makefile.am
@@ -451,7 +451,7 @@ gimpenums.c: $(srcdir)/gimpenums.h $(srcdir)/gimpenums.c.tail $(GIMP_MKENUMS) Ma
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_domain (type, GETTEXT_PACKAGE \"-libgimp\");\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > xgen-cec \
        && cat $(srcdir)/gimpenums.c.tail >> xgen-cec \
diff --git a/libgimpbase/Makefile.am b/libgimpbase/Makefile.am
index a836498..2f3ac24 100644
--- a/libgimpbase/Makefile.am
+++ b/libgimpbase/Makefile.am
@@ -211,7 +211,7 @@ xgen-bec: $(srcdir)/gimpbaseenums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_domain (type, GETTEXT_PACKAGE \"-libgimp\");\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
@@ -235,7 +235,7 @@ xgen-cec: $(srcdir)/gimpcompatenums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_domain (type, GETTEXT_PACKAGE \"-libgimp\");\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/libgimpconfig/Makefile.am b/libgimpconfig/Makefile.am
index 801b91a..40d30ca 100644
--- a/libgimpconfig/Makefile.am
+++ b/libgimpconfig/Makefile.am
@@ -146,7 +146,7 @@ xgen-cec: $(srcdir)/gimpconfigenums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_domain (type, GETTEXT_PACKAGE \"-libgimp\");\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 
diff --git a/libgimpwidgets/Makefile.am b/libgimpwidgets/Makefile.am
index 56cbb61..f55ca4e 100644
--- a/libgimpwidgets/Makefile.am
+++ b/libgimpwidgets/Makefile.am
@@ -315,7 +315,7 @@ xgen-wec: $(srcdir)/gimpwidgetsenums.h $(GIMP_MKENUMS) Makefile.am
                --vprod "    { @VALUENAME@, \"@VALUENAME@\", \"@valuenick@\" }," \
                --vtail "    { 0, NULL, NULL }\n  };\n" \
                --dhead "  static const Gimp@Type@Desc descs[] =\n  {" \
-               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ }," \
+               --dprod "    { @VALUENAME@, @valuedesc@, @valuehelp@ },@if ('@valueabbrev@' ne 'NULL')@\n    
/* Translators: this is an abbreviated version of @valueudesc@.\n       Keep it short. */\n    { @VALUENAME@, 
@valueabbrev@, NULL },@endif@" \
                --dtail "    { 0, NULL, NULL }\n  };\n\n  static GType type = 0;\n\n  if (G_UNLIKELY (! 
type))\n    {\n      type = g_@type@_register_static (\"@EnumName@\", values);\n      
gimp_type_set_translation_domain (type, GETTEXT_PACKAGE \"-libgimp\");\n      
gimp_type_set_translation_context (type, \"@enumnick@\");\n      gimp_@type@_set_value_descriptions (type, 
descs);\n    }\n\n  return type;\n}\n" \
                $< > $@
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]