[libgsf] i18n fixes



commit 82e6b47866856d7d54f36a32a562838ebf34721f
Author: Morten Welinder <terra gnome org>
Date:   Sun Mar 3 10:19:29 2013 -0500

    i18n fixes

 NEWS                     |    2 ++
 gsf/gsf-infile-tar.c     |    5 +++--
 gsf/gsf-input-gzip.c     |   17 +++++++++++------
 gsf/gsf-open-pkg-utils.c |   23 +++++++++++++++++------
 gsf/gsf-output-csv.c     |   40 ++++++++++++++++++++++++++--------------
 gsf/gsf-output-iconv.c   |   22 ++++++++++++++--------
 po/POTFILES.in           |    4 ++++
 7 files changed, 77 insertions(+), 36 deletions(-)
---
diff --git a/NEWS b/NEWS
index eb623e3..4155bcd 100644
--- a/NEWS
+++ b/NEWS
@@ -2,6 +2,8 @@ libgsf 1.14.27
 
 Morten:
        * Introspection fixes.
+       * Property documentation fixes.
+       * I18n fixes for property strings.
 
 --------------------------------------------------------------------------
 libgsf 1.14.26
diff --git a/gsf/gsf-infile-tar.c b/gsf/gsf-infile-tar.c
index 649ab3b..b624510 100644
--- a/gsf/gsf-infile-tar.c
+++ b/gsf/gsf-infile-tar.c
@@ -26,6 +26,7 @@
 #include <gsf-config.h>
 #include <gsf/gsf-infile-tar.h>
 #include <gsf/gsf.h>
+#include <glib/gi18n-lib.h>
 
 #include <string.h>
 
@@ -538,8 +539,8 @@ gsf_infile_tar_class_init (GObjectClass *gobject_class)
                (gobject_class,
                 PROP_SOURCE,
                 g_param_spec_object ("source",
-                                     "Source",
-                                     "The archive being interpreted.",
+                                     _("Source"),
+                                     _("The archive being interpreted"),
                                      GSF_INPUT_TYPE,
                                      GSF_PARAM_STATIC |
                                      G_PARAM_READWRITE |
diff --git a/gsf/gsf-input-gzip.c b/gsf/gsf-input-gzip.c
index b5556cb..d113bca 100644
--- a/gsf/gsf-input-gzip.c
+++ b/gsf/gsf-input-gzip.c
@@ -23,6 +23,7 @@
 #include <gsf-config.h>
 #include <gsf/gsf-input-gzip.h>
 #include <gsf/gsf.h>
+#include <glib/gi18n-lib.h>
 
 #include <zlib.h>
 #include <string.h>
@@ -490,17 +491,20 @@ gsf_input_gzip_class_init (GObjectClass *gobject_class)
        g_object_class_install_property
                (gobject_class,
                 PROP_RAW,
-                g_param_spec_boolean ("raw", "Raw",
-                                      "Whether to read compressed data with no header and no trailer.",
+                g_param_spec_boolean ("raw",
+                                      _("Raw"),
+                                      _("Whether to read compressed data with no header and no trailer"),
                                       FALSE,
                                       GSF_PARAM_STATIC |
                                       G_PARAM_READWRITE |
                                       G_PARAM_CONSTRUCT_ONLY));
+
        g_object_class_install_property
                (gobject_class,
                 PROP_SOURCE,
-                g_param_spec_object ("source", "Source",
-                                     "Where the compressed data comes from.",
+                g_param_spec_object ("source",
+                                     _("Source"),
+                                     _("Where the compressed data comes from"),
                                      GSF_INPUT_TYPE,
                                      GSF_PARAM_STATIC |
                                      G_PARAM_READWRITE |
@@ -515,8 +519,9 @@ gsf_input_gzip_class_init (GObjectClass *gobject_class)
        g_object_class_install_property
                (gobject_class,
                 PROP_UNCOMPRESSED_SIZE,
-                g_param_spec_int64 ("uncompressed-size", "Size after decompression",
-                                    "The source's uncompressed size",
+                g_param_spec_int64 ("uncompressed-size",
+                                    _("Size after decompression"),
+                                    _("The source's uncompressed size"),
                                     -1, G_MAXINT64, -1,
                                     GSF_PARAM_STATIC |
                                     G_PARAM_READWRITE |
diff --git a/gsf/gsf-open-pkg-utils.c b/gsf/gsf-open-pkg-utils.c
index 91b5083..30a546e 100644
--- a/gsf/gsf-open-pkg-utils.c
+++ b/gsf/gsf-open-pkg-utils.c
@@ -725,14 +725,25 @@ gsf_outfile_open_pkg_class_init (GObjectClass *gobject_class)
        parent_class = g_type_class_peek_parent (gobject_class);
 
        g_object_class_install_property (gobject_class, PROP_SINK,
-                g_param_spec_object ("sink", "Sink", "The GsfOutput that stores the Open Package content.",
-                       GSF_OUTFILE_TYPE, GSF_PARAM_STATIC | G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+                g_param_spec_object ("sink",
+                                     _("Sink"),
+                                     _("The GsfOutput that stores the Open Package content"),
+                                     GSF_OUTFILE_TYPE,
+                                     GSF_PARAM_STATIC | G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+
        g_object_class_install_property (gobject_class, PROP_CONTENT_TYPE,
-                g_param_spec_string ("content-type", "ContentType", "The ContentType stored in the root 
[Content_Types].xml file.",
-                       "", GSF_PARAM_STATIC | G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+                g_param_spec_string ("content-type",
+                                     _("Content type"),
+                                     _("The content type stored in the root [Content_Types].xml file"),
+                                     "",
+                                     GSF_PARAM_STATIC | G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+
        g_object_class_install_property (gobject_class, PROP_IS_DIR,
-                g_param_spec_boolean ("is-dir", "IsDir", "Can the outfile have children.",
-                       FALSE, GSF_PARAM_STATIC | G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
+                g_param_spec_boolean ("is-dir",
+                                      _("Is Directory"),
+                                      _("Can the outfile have children"),
+                                      FALSE,
+                                      GSF_PARAM_STATIC | G_PARAM_READWRITE | G_PARAM_CONSTRUCT_ONLY));
 }
 
 GSF_CLASS (GsfOutfileOpenPkg, gsf_outfile_open_pkg,
diff --git a/gsf/gsf-output-csv.c b/gsf/gsf-output-csv.c
index 83d896e..2f3568d 100644
--- a/gsf/gsf-output-csv.c
+++ b/gsf/gsf-output-csv.c
@@ -24,6 +24,7 @@
 #include <gsf/gsf-output-impl.h>
 #include <gsf/gsf-impl-utils.h>
 #include <gsf/gsf-utils.h>
+#include <glib/gi18n-lib.h>
 #include <glib.h>
 #include <string.h>
 
@@ -328,62 +329,73 @@ gsf_output_csv_class_init (GObjectClass *gobject_class)
        g_object_class_install_property
                (gobject_class,
                 PROP_SINK,
-                g_param_spec_object ("sink", "Sink",
-                                     "Where the compressed data is written.",
+                g_param_spec_object ("sink",
+                                     _("Sink"),
+                                     _("Where the formatted output is written"),
                                      GSF_OUTPUT_TYPE,
                                      GSF_PARAM_STATIC |
                                      G_PARAM_READWRITE));
+
        g_object_class_install_property
                (gobject_class,
                 PROP_QUOTE,
-                g_param_spec_string ("quote", "Quote",
-                                     "The string used for quoting fields.",
+                g_param_spec_string ("quote",
+                                     _("Quote"),
+                                     _("The string used for quoting fields"),
                                      "\"",
                                      GSF_PARAM_STATIC |
                                      G_PARAM_CONSTRUCT |
                                      G_PARAM_READWRITE));
+
        g_object_class_install_property
                (gobject_class,
                 PROP_QUOTING_MODE,
                 g_param_spec_enum ("quoting-mode",
-                                   "Quoting Mode",
-                                   "When to quote fields.",
+                                   _("Quoting Mode"),
+                                   _("When to quote fields"),
                                    GSF_OUTPUT_CSV_QUOTING_MODE_TYPE,
                                    GSF_OUTPUT_CSV_QUOTING_MODE_NEVER,
                                    GSF_PARAM_STATIC |
                                    G_PARAM_CONSTRUCT |
                                    G_PARAM_READWRITE));
+
        g_object_class_install_property
                (gobject_class,
                 PROP_QUOTING_TRIGGERS,
-                g_param_spec_string ("quoting-triggers", "Quoting Triggers",
-                                     "Characters that cause field quoting.",
+                g_param_spec_string ("quoting-triggers",
+                                     _("Quoting Triggers"),
+                                     _("Characters that cause field quoting"),
                                      NULL,
                                      GSF_PARAM_STATIC |
                                      G_PARAM_READWRITE));
+
        g_object_class_install_property
                (gobject_class,
                 PROP_QUOTING_ON_WHITESPACE,
                 g_param_spec_boolean ("quoting-on-whitespace",
-                                      "Quoting On Whitespace",
-                                      "Does initial or terminal whitespace force quoting?",
+                                      _("Quoting On Whitespace"),
+                                      _("Does initial or terminal whitespace force quoting?"),
                                       TRUE,
                                       GSF_PARAM_STATIC |
                                       G_PARAM_READWRITE));
+
        g_object_class_install_property
                (gobject_class,
                 PROP_SEPARATOR,
-                g_param_spec_string ("separator", "Separator",
-                                     "The field separator.",
+                g_param_spec_string ("separator",
+                                     _("Separator"),
+                                     _("The field separator"),
                                      ",",
                                      GSF_PARAM_STATIC |
                                      G_PARAM_CONSTRUCT |
                                      G_PARAM_READWRITE));
+
        g_object_class_install_property
                (gobject_class,
                 PROP_EOL,
-                g_param_spec_string ("eol", "eol",
-                                     "The end-of-line marker.",
+                g_param_spec_string ("eol",
+                                     _("end-on-line"),
+                                     _("The end-of-line marker"),
                                      "\n",
                                      GSF_PARAM_STATIC |
                                      G_PARAM_CONSTRUCT |
diff --git a/gsf/gsf-output-iconv.c b/gsf/gsf-output-iconv.c
index 4d1c789..7196727 100644
--- a/gsf/gsf-output-iconv.c
+++ b/gsf/gsf-output-iconv.c
@@ -22,6 +22,7 @@
 #include <gsf-config.h>
 #include <gsf/gsf-output-iconv.h>
 #include <gsf/gsf.h>
+#include <glib/gi18n-lib.h>
 
 #include <string.h>
 
@@ -271,17 +272,20 @@ gsf_output_iconv_class_init (GObjectClass *gobject_class)
        g_object_class_install_property
                (gobject_class,
                 PROP_SINK,
-                g_param_spec_object ("sink", "Sink",
-                                     "Where the converted data is written.",
+                g_param_spec_object ("sink",
+                                     _("Sink"),
+                                     _("Where the converted data is written"),
                                      GSF_OUTPUT_TYPE,
                                      GSF_PARAM_STATIC |
                                      G_PARAM_READWRITE |
                                      G_PARAM_CONSTRUCT_ONLY));
+
        g_object_class_install_property
                (gobject_class,
                 PROP_INPUT_CHARSET,
-                g_param_spec_string ("input-charset", "Input Charset",
-                                     "The character set to convert from.",
+                g_param_spec_string ("input-charset",
+                                     _("Input Charset"),
+                                     _("The character set to convert from"),
                                      "UTF-8",
                                      GSF_PARAM_STATIC |
                                      G_PARAM_READWRITE |
@@ -289,8 +293,9 @@ gsf_output_iconv_class_init (GObjectClass *gobject_class)
        g_object_class_install_property
                (gobject_class,
                 PROP_OUTPUT_CHARSET,
-                g_param_spec_string ("output-charset", "Output Charset",
-                                     "The character set to convert to.",
+                g_param_spec_string ("output-charset",
+                                     _("Output Charset"),
+                                     _("The character set to convert to"),
                                      "UTF-8",
                                      GSF_PARAM_STATIC |
                                      G_PARAM_READWRITE |
@@ -305,8 +310,9 @@ gsf_output_iconv_class_init (GObjectClass *gobject_class)
        g_object_class_install_property
                (gobject_class,
                 PROP_FALLBACK,
-                g_param_spec_string ("fallback", "Fallback",
-                                     "The string to use for invalid characters.",
+                g_param_spec_string ("fallback",
+                                     _("Fallback"),
+                                     _("The string to use for invalid characters"),
                                      NULL,
                                      GSF_PARAM_STATIC |
                                      G_PARAM_READWRITE));
diff --git a/po/POTFILES.in b/po/POTFILES.in
index 475272c..4121854 100644
--- a/po/POTFILES.in
+++ b/po/POTFILES.in
@@ -3,7 +3,9 @@
 [encoding: UTF-8]
 gsf/gsf-blob.c
 gsf/gsf-clip-data.c
+gsf/gsf-infile-tar.c
 gsf/gsf-infile-zip.c
+gsf/gsf-input-gzip.c
 gsf/gsf-input-http.c
 gsf/gsf-input.c
 gsf/gsf-libxml.c
@@ -11,5 +13,7 @@ gsf/gsf-msole-utils.c
 gsf/gsf-open-pkg-utils.c
 gsf/gsf-opendoc-utils.c
 gsf/gsf-outfile-zip.c
+gsf/gsf-output-csv.c
+gsf/gsf-output-iconv.c
 gsf/gsf-output.c
 tools/gsf.c


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