From 3c450ebc97056c8882289b95abdf7573ce80b54e Mon Sep 17 00:00:00 2001 From: Christian Dywan Date: Sat, 8 Nov 2008 03:05:30 +0100 Subject: [PATCH] Introduce descriptive comments meant to help translators intltool automatically embeds comments in the po template if they are directly before a translatable string. From now on we will try to avoid leaving accidental comments and instead put descriptive comments for translators before strings, starting with 'i18n'. --- TRANSLATE | 5 +++++ midori/main.c | 3 ++- midori/midori-browser.c | 4 +++- midori/midori-preferences.c | 2 +- midori/midori-view.c | 2 +- midori/midori-websettings.c | 1 + po/POTFILES.skip | 1 + 7 files changed, 14 insertions(+), 4 deletions(-) diff --git a/TRANSLATE b/TRANSLATE index 133ed47b..3c151c52 100644 --- a/TRANSLATE +++ b/TRANSLATE @@ -18,3 +18,8 @@ msgfmt -c --check-accelerators=_ aa.po As a general rule, your localization should be based off of the current state of the git repository. + +Some strings have comments, starting with 'i18n', which are meant +to describe the role of a string to translators. +Please don't hesitate to ask for additional descriptive comments +for any unclear strings that you are uncertain about. diff --git a/midori/main.c b/midori/main.c index 550e5722..1e0102c9 100644 --- a/midori/main.c +++ b/midori/main.c @@ -861,6 +861,7 @@ midori_history_terminate (sqlite3* db, db_exec (db, sqlcmd, &error); if (!success) { + /* i18n: Couldn't remove items that are older than n days */ g_printerr (_("Failed to remove old history items: %s\n"), error->message); g_error_free (error); return ; @@ -1152,8 +1153,8 @@ main (int argc, if (result) return 0; - /* FIXME: Do we want a graphical error message? */ g_print (_("An instance of Midori is already running but not responding.\n")); + /* FIXME: Do we want a graphical error message? */ return 1; } diff --git a/midori/midori-browser.c b/midori/midori-browser.c index 1b5eb90a..22278632 100644 --- a/midori/midori-browser.c +++ b/midori/midori-browser.c @@ -3794,6 +3794,7 @@ midori_browser_init (MidoriBrowser* browser) gtk_widget_show (browser->panel_pageholder); midori_panel_append_page (MIDORI_PANEL (browser->panel), browser->panel_pageholder, NULL, + /* i18n: A panel showing a user specified web page */ STOCK_PAGE_HOLDER, _("Pageholder")); /* Userscripts */ @@ -3862,7 +3863,8 @@ midori_browser_init (MidoriBrowser* browser) toolitem = gtk_tool_item_new (); gtk_container_set_border_width (GTK_CONTAINER (toolitem), 6); gtk_container_add (GTK_CONTAINER (toolitem), - gtk_label_new_with_mnemonic (_("_Inline find:"))); + /* i18n: A panel at the bottom, to search text in pages */ + gtk_label_new_with_mnemonic (_("_Inline find:"))); gtk_toolbar_insert (GTK_TOOLBAR (browser->find), toolitem, -1); browser->find_text = gtk_icon_entry_new (); gtk_icon_entry_set_icon_from_stock (GTK_ICON_ENTRY (browser->find_text), diff --git a/midori/midori-preferences.c b/midori/midori-preferences.c index 4a524c2f..ce657c8d 100644 --- a/midori/midori-preferences.c +++ b/midori/midori-preferences.c @@ -342,9 +342,9 @@ midori_preferences_set_settings (MidoriPreferences* preferences, FILLED_ADD (button, 1, 2, 0, 1); label = katze_property_label (settings, "homepage"); INDENTED_ADD (label, 0, 1, 1, 2); + /* TODO: We need something like "use current website" */ entry = katze_property_proxy (settings, "homepage", NULL); FILLED_ADD (entry, 1, 2, 1, 2); - /* TODO: We need something like "use current website" */ FRAME_NEW (_("Transfers")); TABLE_NEW (3, 2); label = katze_property_label (settings, "download-folder"); diff --git a/midori/midori-view.c b/midori/midori-view.c index 216aa871..a9d9ac0e 100644 --- a/midori/midori-view.c +++ b/midori/midori-view.c @@ -895,7 +895,6 @@ webkit_web_view_populate_popup_cb (WebKitWebView* web_view, if (!view->link_uri && !has_selection) { - /* FIXME: Make this sensitive only when there is a tab to undo */ menuitem = gtk_image_menu_item_new_with_mnemonic (_("Undo Close Tab")); icon = gtk_image_new_from_stock (GTK_STOCK_UNDELETE, GTK_ICON_SIZE_MENU); gtk_image_menu_item_set_image (GTK_IMAGE_MENU_ITEM (menuitem), icon); @@ -903,6 +902,7 @@ webkit_web_view_populate_popup_cb (WebKitWebView* web_view, g_object_set_data (G_OBJECT (menuitem), "action", "UndoTabClose"); g_signal_connect (menuitem, "activate", G_CALLBACK (midori_web_view_menu_action_activate_cb), view); + /* FIXME: Make this sensitive only when there is a tab to undo */ gtk_widget_show (menuitem); menuitem = gtk_separator_menu_item_new (); gtk_menu_shell_append (GTK_MENU_SHELL (menu), menuitem); diff --git a/midori/midori-websettings.c b/midori/midori-websettings.c index 19ea94c3..fc6b1ba0 100644 --- a/midori/midori-websettings.c +++ b/midori/midori-websettings.c @@ -277,6 +277,7 @@ midori_web_settings_class_init (MidoriWebSettingsClass* class) PROP_LAST_PANEL_PAGE, g_param_spec_int ( "last-panel-page", + /* i18n: The internal index of the last opened panel */ _("Last panel page"), _("The last saved panel page"), 0, G_MAXINT, 0, diff --git a/po/POTFILES.skip b/po/POTFILES.skip index 810789ee..8468b7fe 100644 --- a/po/POTFILES.skip +++ b/po/POTFILES.skip @@ -1 +1,2 @@ # List of source files containing translatable strings but should be ignored. +midori/gtkiconentry.c -- 2.39.5