summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorEmmanuele Bassi <ebassi@gnome.org>2008-12-19 22:48:36 +0000
committerEmmanuele Bassi <ebassi@src.gnome.org>2008-12-19 22:48:36 +0000
commit4a55be13f3d13c895c1dd7f26120ad49b22739f3 (patch)
tree76edfb5373754c155a548e17389b858035032dee /src
parentb56c58e27b81871cc0cf25e235692a7266ca6c62 (diff)
downloadgnome-dictionary-4a55be13f3d13c895c1dd7f26120ad49b22739f3.tar.gz
Bug 454691 – Messages in the gnome-dictionary --help output are not all
2008-12-19 Emmanuele Bassi <ebassi@gnome.org> Bug 454691 – Messages in the gnome-dictionary --help output are not all translated * libgdict/gdict-utils.c: Mark debug command line options as translatable. * src/gdict-app.c (gdict_init): Fix translation of the command line options. (Gabor Kelemen) svn path=/trunk/; revision=8210
Diffstat (limited to 'src')
-rw-r--r--src/gdict-app.c26
1 files changed, 10 insertions, 16 deletions
diff --git a/src/gdict-app.c b/src/gdict-app.c
index f264659..a909418 100644
--- a/src/gdict-app.c
+++ b/src/gdict-app.c
@@ -322,7 +322,6 @@ gdict_init (int *argc, char ***argv)
{
GError *gconf_error, *err = NULL;
GOptionContext *context;
- GOptionGroup *group;
gchar *loader_path;
gchar **lookup_words = NULL;
gchar **match_words = NULL;
@@ -367,26 +366,21 @@ gdict_init (int *argc, char ***argv)
/* create the new option context */
context = g_option_context_new (_(" - Look up words in dictionaries"));
- /* gnome dictionary option group */
- group = g_option_group_new ("gnome-dictionary",
- _("Dictionary and spelling tool"),
- _("Show Dictionary options"),
- NULL, NULL);
- g_option_group_add_entries (group, gdict_app_goptions);
- g_option_context_set_main_group (context, group);
+ g_option_context_set_translation_domain (context, GETTEXT_PACKAGE);
+ g_option_context_add_main_entries (context, gdict_app_goptions, GETTEXT_PACKAGE);
g_option_context_add_group (context, gdict_get_option_group ());
g_option_context_add_group (context, gtk_get_option_group (TRUE));
g_option_context_parse (context, argc, argv, &err);
+ if (err)
+ {
+ g_critical ("Failed to parse argument: %s", err->message);
+ g_error_free (err);
+ g_option_context_free (context);
+ gdict_cleanup ();
- if (err) {
- g_critical ("Failed to parse argument: %s", err->message);
- g_error_free (err);
- g_option_context_free (context);
- gdict_cleanup ();
-
- exit (1);
- }
+ exit (1);
+ }
g_set_application_name (_("Dictionary"));
gtk_window_set_default_icon_name ("accessories-dictionary");