Re: [GNC] Decimal separator on Gnucash 3.2 Mac (fixed !!!)

2018-08-04 Thread Yves Forget via gnucash-user
Problem fixed. I thought I’d share with the list in case the problem happens to someone else. I installed GnuCash short after upgrading from OSX 10.9 to 10.13. Gnucash uses period as decimal separator, while here in French Canada decimal separator should be comma. After asking the list I saw

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-03 Thread John Ralls
Yves, And just for completeness I added a line to read NSLocaleDecimalSeparator and then examined it in the debugger. It's '.', consistent with the locale being en_CA instead of fr_CA. Regards, John Ralls > On Jul 2, 2018, at 7:57 PM, John Ralls wrote: > > Yves, > > No, unfortunately quer

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread Bert Riding
I don't know about Macs, but the POSIX locale categories for this are LC_MONETARY for how monetary quantities are shown, and LC_NUMERIC for other numbers, defining decimal and thousands seperators among other things. See locale(5). On Mon, 2 Jul 2018 15:43:46 -0700 John Ralls wrote: > I tested

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread John Ralls
Yves, No, unfortunately querying NSLocaleDecimalSeparator and friends won’t help. GnuCash depends at least partly on libc functions like printf (and their C++ equivalents) for formatting, and those functions in turn depend on a locale being set in the environment. They use that locale to retri

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread Yves Forget via gnucash-user
Hi John, Running from the terminal I still get period. In the terminal I got the following trace. (process:1976): gnc.gui-WARNING **: 18:35:55.003: [mac_set_languages()] Language list: en:fr_CA:en_CA:C I just downloaded the sources from GitHub, and looked at [mac_set_languages

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread Yves Forget via gnucash-user
Hi John, Running from the terminal I still get period. In the terminal I got the following trace. (process:1976): gnc.gui-WARNING **: 18:35:55.003: [mac_set_languages()] Language list: en:fr_CA:en_CA:C I just downloaded the sources from GitHub, and looked at [mac_set_languages()]. Foundatio

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread John Ralls
I tested this a bit in the debugger and I with French as the primary language and Canada as the country [currentlocale objectForKey: NSLocaleLanguageCode] insists that the code in en, not French. If I tell System Prefs I'm in France it gets the right answer, so it might be an Apple bug. Unfort

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread John Ralls
If you run GnuCash from a Terminal prompt do you get the right separator? Regards, John Ralls > On Jul 2, 2018, at 1:42 PM, Yves Forget via gnucash-user > wrote: > > System Preferences/Language and Region says Region = Canada and language = > french. Advanced shows decimal separator is comma

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread Yves Forget via gnucash-user
System Preferences/Language and Region says Region = Canada and language = french.  Advanced shows decimal separator is comma and thousands separator is space.  (These are default values for French Canada). Environment variable LANG=fr_CA.UTF_8 OpenOffice correctly uses comma as decimal separator

Re: [GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread R. Victor Klassen
Maybe in Quebec it is a comma. In the rest of the country it is a period. There should be a different locale for fr-canada than for en-canada. I don’t know what else would differ across locales though. > On Jul 2, 2018, at 3:42 PM, Yves Forget via gnucash-user > wrote: > > I’m new to Gn

[GNC] Decimal separator on Gnucash 3.2 Mac

2018-07-02 Thread Yves Forget via gnucash-user
I’m new to GnuCash and just installed GnuCash 3.2 on Mac. OS X 10.13 Gnucash uses the period as decimal separator instead of my locale’s separator. Here in Canada it should be comma. Should Gnucash use the decimal separator of my locale, or is it always period ? Is there a way to c