gnucash maint: Remove bare percent sign in taxinvoice.scm, replace with English.

Jeff Earickson jaearick at colby.edu
Tue Oct 21 16:03:14 EDT 2014


Derek,

Hmmm...  Trying to reproduce here.  Sometimes msgfmt will compile the po
file fine, but poedit will complain, so the two are not consistent.

In the case I just tried, poedit said:

"Error: 'msgstr'' is not a valid C format string, unlike 'msgid'.  Reason:
the character that erminates the directive number 1 is not a valid
conversion specifier."

But that same exact file just compiled with msgfmt just fine.  Ugh.


-----------------------------------
Jeff A. Earickson, Ph.D
Senior Server System Administrator
Colby College,
4214 Mayflower Hill,
Waterville ME, 04901-8842
207-859-4214 (fax 207-859-4186)
Eastern Time Zone, USA
-----------------------------------

On Tue, Oct 21, 2014 at 12:20 PM, Derek Atkins <derek at ihtfp.com> wrote:

>  Could you provide the exact compiler error you get, including the
> commands to reproduce it?
>
> -derek
>
> Sent on my mobile. Please forgive any typos.
>
> ----- Reply message -----
> From: "Jeff Earickson" <jaearick at colby.edu>
> To: "Geert Janssens" <geert.gnucash at kobaltwit.be>
> Cc: "Gnucash-devel" <gnucash-devel at gnucash.org>
> Subject: gnucash maint: Remove bare percent sign in taxinvoice.scm,
> replace with English.
> Date: Tue, Oct 21, 2014 11:56 AM
>
> Geert,
>
> Well, "10 percent" and "32 pixels" are literal examples too.  In my efforts
> on getting the Indic language translations to compile, poedit and/or the
> compile sequence always seems to choke on this spot.  The English
> translation of:
>
> :... e.g. 10% or 32px"
>
> ends up in the following translated string as:
>
> "[characters in Devanagari]% [more chars] 32px [more chars]"
>
> and the compiler sees the "%" as a "bare character" when it expects "%d" or
> "%s" or "\%" or "%%" or something in proper C format.  Compiler error.
>
> I have tried all of the usual C/perl forms of making it a compilable
> string, like "\%", "%%", adding a space in front of it -- no success.  My
> usual work-around is to simply remove the percent sign, which is wrong.  I
> am open to suggestions here.
>
> I am hoping/assuming that most languages would have some equivalent of the
> English word "percent" that could be used, even if it reads as "parts per
> hundred" in the native language.  I am less concerned about changing "px"
> to "pixel", but I like proper English.
>
> --- Jeff Earickson
>
> On Tue, Oct 21, 2014 at 11:28 AM, Geert Janssens <geert.gnucash at kobaltwit.be
> > wrote:
>
> > On Monday 13 October 2014 13:53:51 John Ralls wrote:
> > > commit 289bfc2aefdf203881bc3e130cc98aa720e558df
> > > Author: Jeff Earickson <jaearick at colby.edu>
> > > Date:   Sun Oct 12 22:29:40 2014 -0400
> > >
> > >     Remove bare percent sign in taxinvoice.scm, replace with English.
> > >
> > >     The bare percent sign in this string messes with po translation
> > >     files and causes difficulties compiling without backslashes and
> > >     other pain.  Cleans up the English by using real words.
> > >
> > I'm still pondering if this patch should have been applied or not.
> >
> > The '10%' and '32px' are literal examples of values to enter in the text
> > box. '10 percent' and '32
> > pixels' are not so the help message lost some of its helpfulness.
> >
> > What problems do you experience during translation ?
> >
> > Geert
> >
> > > diff --git a/src/report/business-reports/taxinvoice.scm
> > > b/src/report/business-reports/taxinvoice.scm index 106f8d7..ce7c0ed
> > > 100644
> > > --- a/src/report/business-reports/taxinvoice.scm
> > > +++ b/src/report/business-reports/taxinvoice.scm
> > > @@ -193,7 +193,7 @@
> > >                  (N_ "Name of a file containing a logo to be used on
> > > the report.") ""))
> > >    (add-option (gnc:make-string-option
> > > -                displaypage optname-logo-width "f" (N_ "Width of the
> > > logo in CSS format, e.g. 10% or 32px. Leave blank to display the logo
> > > at its natural width. The height of the logo will be scaled
> > > accordingly.") "")) +                displaypage optname-logo-width
> > > "f" (N_ "Width of the logo in CSS format, e.g. 10 percent or 32
> > > pixels. Leave blank to display the logo at its natural width. The
> > > height of the logo will be scaled accordingly.") "")) (add-option
> > > (gnc:make-simple-boolean-option       displaypage
> >  optname-border-collapse "
> > > g" (N_ "Border-collapse?") #f)) (add-option
> > > (gnc:make-string-option               displaypage
> >  optname-border-color-th "h" (N_
> > > "CSS color.") "black")) (add-option
> > > (gnc:make-string-option               displaypage
> >  optname-border-color-td "i" (N_
> > > "CSS color.") "black"))
> > >
> > >
> > >
> > > Summary of changes:
> > >  src/engine/gnc-budget.c                    | 6 ++++--
> > >  src/report/business-reports/taxinvoice.scm | 2 +-
> > >  2 files changed, 5 insertions(+), 3 deletions(-)
> > >
> > > _______________________________________________
> > > gnucash-changes mailing list
> > > gnucash-changes at gnucash.org
> > > https://lists.gnucash.org/mailman/listinfo/gnucash-changes
> >
> > _______________________________________________
> > gnucash-devel mailing list
> > gnucash-devel at gnucash.org
> > https://lists.gnucash.org/mailman/listinfo/gnucash-devel
> >
> _______________________________________________
> gnucash-devel mailing listgnucash-devel at gnucash.orghttps://lists.gnucash.org/mailman/listinfo/gnucash-devel
>
>


More information about the gnucash-devel mailing list