space seperator between currency symbol and amount

Christian Stimming stimming@tuhh.de
Tue, 12 Jun 2001 20:56:36 +0200


-----BEGIN PGP SIGNED MESSAGE-----

I just found out about this today, and maybe other people were wondering 
about that too, so here's my solution: 

In my locale (de_DE) the currency symbol (i.e. the german version of "$" 
which is "DM") was printed in front of the amount without a seperating 
space: "DM823,21". IMHO this looks pretty ugly. After some digging and 
RTFM, it turned out that this is not a GnuCash related problem. Instead, 
the system's locale contains information on whether or not there should be 
a seperator at the mentioned point. Since I wasn't satified with the 
current setting, I had to compile a new locale file. The source code for 
the locale can be found in  /usr/share/i18n/locales/*, i.e. 
/usr/share/i18n/locales/de_DE for me. I had to change the values for the 
key words p_sep_by_space and n_sep_by_space (in the section LC_MONETARY 
almost at the end of the file), and I changed those from 0 to 1. After the 
file editing, I had to compile the edited locale source with localedef(1) 
which in my case looked like this:

localedef -f ISO-8859-1 -i de_DE  /usr/share/locale/de_DE

This indeed changed the amount printing in the desired way, i.e. I now get 
"DM 823,21". 

Christian
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.4 (GNU/Linux)

iQCVAwUBOyZl5GXAi+BfhivFAQGNigP+LKLTIbsu9oPmmtgNytXz5qxqEO2PIqp2
28VWOb8FFusu3iOTRDVudY+bgrUjUoXq2YnBUhjAaHenIL0QGPVi6y3zNpB/b5K0
1952WaQmxF4wRCajRjOgtaO3W9CLt5VRI5d0Jk7nTJCGPmskJDW8jT9JYl1S1C3v
9IVhb8g8dbs=
=TPs0
-----END PGP SIGNATURE-----