Improve the for translators problematic format string from gnc_entry_ledger_verify_acc_cell_ok

This version uses 2 separate sentences,
mentions currencies and
gives a clue for the account type.
Add enable basic doxygen output.

git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@20089 57a11ea4-9604-0410-9ed3-97b8803252fd
This commit is contained in:
Frank H. Ellenberger 2011-01-13 23:12:41 +00:00
parent 15bc162e7c
commit d47c7c5ec0

View File

@ -1,9 +1,10 @@
/*
* gncEntryLedgerControl.c -- Control for GncEntry ledger
/** \file gncEntryLedgerControl.c
* \brief Control for GncEntry ledger
*
* Copyright (C) 2001, 2002, 2003 Derek Atkins
* Author: Derek Atkins <warlord@MIT.EDU>
* Copyright (C) 2010 Christian Stimming <christian@cstimming.de>
*
* Copyright (C) 2010 Christian Stimming <christian@cstimming.de> */
/*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of
@ -149,16 +150,16 @@ gnc_entry_ledger_verify_acc_cell_ok (GncEntryLedger *ledger,
name = cell->cell.value;
if (!name || *name == '\0')
{
/* Translators: %s is the string "an Account" i.e. its translation. */
const char *format = _("Invalid Entry: You need to supply %s.");
const char *format = ("%s %s");
const char *gen_msg = _("Invalid Entry: You need to supply an account in the right currency for this position.");
gnc_error_dialog (ledger->parent, format, cell_msg);
gnc_error_dialog (ledger->parent, format, gen_msg, cell_msg);
return FALSE;
}
return TRUE;
}
/* Verify whether we can save the entry, or warn the user when we can't
/** Verify whether we can save the entry, or warn the user when we can't
* return TRUE if we can save, FALSE if there is a problem
*/
static gboolean
@ -176,13 +177,13 @@ gnc_entry_ledger_verify_can_save (GncEntryLedger *ledger)
{
case GNCENTRY_INVOICE_ENTRY:
if (!gnc_entry_ledger_verify_acc_cell_ok (ledger, ENTRY_IACCT_CELL,
_("an Account")))
_("This account should usually be of type income.")))
return FALSE;
break;
case GNCENTRY_BILL_ENTRY:
case GNCENTRY_EXPVOUCHER_ENTRY:
if (!gnc_entry_ledger_verify_acc_cell_ok (ledger, ENTRY_BACCT_CELL,
_("an Account")))
_("This account should usually be of type expense or asset.")))
return FALSE;
break;
default: