gnucash maint: [I18N] Bug 797349 - "A"ssociate header badly translated

Frank H.Ellenberger fell at code.gnucash.org
Sat Sep 7 13:51:41 EDT 2019


Updated	 via  https://github.com/Gnucash/gnucash/commit/92bae3fe (commit)
	from  https://github.com/Gnucash/gnucash/commit/a940434e (commit)



commit 92bae3fe3e9af07462321f9993d557818cdbb93d
Author: Frank H. Ellenberger <frank.h.ellenberger at gmail.com>
Date:   Sat Sep 7 03:31:31 2019 +0200

    [I18N] Bug 797349 - "A"ssociate header badly translated
    
    A few more messages

diff --git a/gnucash/register/ledger-core/gncEntryLedgerLayout.c b/gnucash/register/ledger-core/gncEntryLedgerLayout.c
index 0bae34c27..c1a59e672 100644
--- a/gnucash/register/ledger-core/gncEntryLedgerLayout.c
+++ b/gnucash/register/ledger-core/gncEntryLedgerLayout.c
@@ -71,91 +71,91 @@ static void gnc_entry_ledger_layout_add_cells (GncEntryLedger *ledger,
         /* Translators: The following strings are used for the layout of the
            cells while editing invoices.
            Important: The 'sample:' items are strings which are not
-           displayed, but only used to estimate widths. Please only
-           translate the portion after the ':' and leave the rest
-           ("sample:") as is.
+           displayed, but only used to estimate widths.
            This sample is for a checkbox */
         {
-            ENTRY_INV_CELL, CHECKBOX_CELL_TYPE_NAME, N_("sample:X") + 7,
+            ENTRY_INV_CELL, CHECKBOX_CELL_TYPE_NAME, C_("sample for a checkbox", "X"),
             CELL_ALIGN_LEFT, FALSE, FALSE
         },
         {
-            /* Translators: This sample is for a date */
-            ENTRY_DATE_CELL, DATE_CELL_TYPE_NAME, N_("sample:12/12/2000") + 7,
+            ENTRY_DATE_CELL, DATE_CELL_TYPE_NAME, C_("sample for 'Date'", "12/12/2000"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
             ENTRY_DESC_CELL, QUICKFILL_CELL_TYPE_NAME,
-            N_("sample:Description of an Entry") + 7, CELL_ALIGN_LEFT, TRUE, FALSE
+            C_("sample for 'Description'", "Description of an Entry"), CELL_ALIGN_LEFT,
+	    TRUE, FALSE
         },
         {
+            /* Translators: Enter the longest 'Action' entry */
             ENTRY_ACTN_CELL, COMBO_CELL_TYPE_NAME,
-            N_("sample:Action") + 7, CELL_ALIGN_RIGHT,
+            C_("sample", "Action"), CELL_ALIGN_RIGHT,
             FALSE, FALSE
         },
         {
-            ENTRY_QTY_CELL, PRICE_CELL_TYPE_NAME, N_("sample:9,999.00") + 7,
+            ENTRY_QTY_CELL, PRICE_CELL_TYPE_NAME, C_("sample", "9,999.00"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
-            ENTRY_PRIC_CELL, PRICE_CELL_TYPE_NAME, N_("sample:999,999.00") + 7,
+            ENTRY_PRIC_CELL, PRICE_CELL_TYPE_NAME, C_("sample", "999,999.00"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
-            ENTRY_DISC_CELL, PRICE_CELL_TYPE_NAME, N_("sample:9,999.00") + 7,
+            ENTRY_DISC_CELL, PRICE_CELL_TYPE_NAME, C_("sample", "9,999.00"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
             /* xgettext:no-c-format
                Translators: Header for Discount Type */
-            ENTRY_DISTYPE_CELL, RECN_CELL_TYPE_NAME, N_("sample(DT):+%") + 11,
+            ENTRY_DISTYPE_CELL, RECN_CELL_TYPE_NAME, C_("sample for 'Discount Type'", "+%"),
             CELL_ALIGN_LEFT, FALSE, FALSE
         },
         {
             /* xgettext:no-c-format
                Translators: Header for Discount How */
-            ENTRY_DISHOW_CELL, RECN_CELL_TYPE_NAME, N_("sample(DH):+%") + 11,
+            ENTRY_DISHOW_CELL, RECN_CELL_TYPE_NAME, C_("sample for Discount How'", "+%"),
             CELL_ALIGN_LEFT, FALSE, FALSE
         },
         {
             ENTRY_IACCT_CELL, COMBO_CELL_TYPE_NAME,
-            N_("sample:Expenses:Automobile:Gasoline") + 7,
+            /* Translators: Enter the longest expected path of an Account */
+            C_("sample", "Expenses:Automobile:Gasoline"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
             ENTRY_BACCT_CELL, COMBO_CELL_TYPE_NAME,
-            N_("sample:Expenses:Automobile:Gasoline") + 7,
+            C_("sample", "Expenses:Automobile:Gasoline"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
             /* Translators: Abbreviation sample for Taxable? */
-            ENTRY_TAXABLE_CELL, CHECKBOX_CELL_TYPE_NAME, N_("sample:T?") + 7,
+            ENTRY_TAXABLE_CELL, CHECKBOX_CELL_TYPE_NAME, C_("sample for 'Taxable'", "T?"),
             CELL_ALIGN_LEFT, FALSE, FALSE
         },
         {
             /* Translators: Abbreviation sample for Tax Included */
-            ENTRY_TAXINCLUDED_CELL, CHECKBOX_CELL_TYPE_NAME, N_("sample:TI") + 7,
+            ENTRY_TAXINCLUDED_CELL, CHECKBOX_CELL_TYPE_NAME, C_("sample for 'Tax Included'", "TI"),
             CELL_ALIGN_LEFT, FALSE, FALSE
         },
         {
-            ENTRY_TAXTABLE_CELL, COMBO_CELL_TYPE_NAME, N_("sample:Tax Table 1") + 7,
+            ENTRY_TAXTABLE_CELL, COMBO_CELL_TYPE_NAME, C_("sample for 'Tax Table'", "Tax Table 1"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
-            ENTRY_VALUE_CELL, PRICE_CELL_TYPE_NAME, N_("sample:999,999.00") + 7,
+            ENTRY_VALUE_CELL, PRICE_CELL_TYPE_NAME, C_("sample", "999,999.00"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
-            ENTRY_TAXVAL_CELL, PRICE_CELL_TYPE_NAME, N_("sample:999.00") + 7,
+            ENTRY_TAXVAL_CELL, PRICE_CELL_TYPE_NAME, C_("sample", "999.00"),
             CELL_ALIGN_RIGHT, FALSE, FALSE
         },
         {
             /* Translators: Abbreviation sample for Billable */
-            ENTRY_BILLABLE_CELL, CHECKBOX_CELL_TYPE_NAME, N_("sample:BI") + 7,
+            ENTRY_BILLABLE_CELL, CHECKBOX_CELL_TYPE_NAME, C_("sample for 'Billable'", "BI"),
             CELL_ALIGN_LEFT, FALSE, FALSE
         },
         {
-            ENTRY_PAYMENT_CELL, COMBO_CELL_TYPE_NAME, N_("sample:Payment") + 7,
+            ENTRY_PAYMENT_CELL, COMBO_CELL_TYPE_NAME, C_("sample", "Payment"),
             CELL_ALIGN_LEFT, FALSE, FALSE
         }
     };
diff --git a/gnucash/register/ledger-core/split-register-layout.c b/gnucash/register/ledger-core/split-register-layout.c
index ef5441266..bce4d73f0 100644
--- a/gnucash/register/ledger-core/split-register-layout.c
+++ b/gnucash/register/ledger-core/split-register-layout.c
@@ -810,11 +810,7 @@ gnc_split_register_layout_add_cells (SplitRegister *reg,
     gnc_register_add_cell (layout,
                            TYPE_CELL,
                            RECN_CELL_TYPE_NAME,
-	                          /* Translators: The abbreviation for 'Type'
-	                              in the header row of the register. Please only
-	                              translate the portion after the ':' and
-	                              leave the rest ("Type:") as is. */
-	                            N_("Type:T") + 5,
+	                   C_("Column header for 'Type'", "T"),
                            CELL_ALIGN_CENTER,
                            FALSE,
                            FALSE);



Summary of changes:
 .../register/ledger-core/gncEntryLedgerLayout.c    | 44 +++++++++++-----------
 .../register/ledger-core/split-register-layout.c   |  6 +--
 2 files changed, 23 insertions(+), 27 deletions(-)



More information about the gnucash-changes mailing list