Writing cheques

David Reiser dbreiser at earthlink.net
Sat Sep 9 13:14:52 EDT 2006


On Sep 9, 2006, at 9:55 AM, Doug Laidlaw wrote:

> Yes, I understand why it happens.  I am not a programmer, and  
> simply assumed
> that the date format set for the program would apply throughout,  
> whether it
> came from i18n, or from the config itself. I did raise this a while  
> back
> under earlier versions.  I can't remember what I was told back then.
>
> But what  I REALLY asked was this:
>
> ' instead of "...and 99/100" the convention here is "...and 99  
> cents".  I
> can see where this is set, but the correct syntax to change it  
> isn't obvious.'
>
> [...]
> Doug.
  Looks to me like in number-to-words.scm, if you take the part that  
says:

           (string-append (integer-to-words int-part) " and "
                          (with-output-to-string
                            (lambda ()
                              (write frac-part)
                              (display "/")
                              (write frac-denom)))))

and make it say

           (string-append (integer-to-words int-part) " and "
                          (with-output-to-string
                            (lambda ()
                              (write frac-part)
                              (display " cents")))))

you might get what you want. This is ugly as a patch, because I think  
it leaves dead code related to the determination of frac-denom, but I  
don't think the remnants get in the way.

--
David Reiser
dbreiser at earthlink.net



More information about the gnucash-user mailing list