You are not logged in.

#1 2012-10-02 04:12:06

Joel
Member
From: Tijuana, BC, México
Registered: 2011-12-21
Posts: 84

[SOLVED] Decimal separator is incorrect for es_MX

Hello!

I just notice that my decimal separator is wrong...

Current: , (coma)
Correnct: . (dot)

How to change it?

Last edited by Joel (2012-10-03 00:09:51)


* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with xfce4.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with xfce4.
* AUR contributor.

Offline

#2 2012-10-02 06:38:23

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [SOLVED] Decimal separator is incorrect for es_MX


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

#3 2012-10-02 11:43:30

Alber
Member
From: Spain - España
Registered: 2011-11-11
Posts: 174

Re: [SOLVED] Decimal separator is incorrect for es_MX

Try command locale.
Maybe changing LC_NUMERIC and LC_MONETARY to another language in /etc/locale.conf, it works as you want.
Don't forget launch locale-gen.
https://wiki.archlinux.org/index.php/Locale

Offline

#4 2012-10-02 13:10:51

karol
Archivist
Registered: 2009-05-06
Posts: 25,433

Re: [SOLVED] Decimal separator is incorrect for es_MX

How locale works in Arch: https://plus.google.com/114015603831160 … zKCcnTWDpa

If you can't fix it yourself, post the output of 'locale' and 'locale -a'.

Offline

#5 2012-10-02 15:20:07

Joel
Member
From: Tijuana, BC, México
Registered: 2011-12-21
Posts: 84

Re: [SOLVED] Decimal separator is incorrect for es_MX

locale

LANG=es_MX.UTF-8
LC_CTYPE="es_MX.UTF-8"
LC_NUMERIC="es_MX.UTF-8"
LC_TIME="es_MX.UTF-8"
LC_COLLATE="es_MX.UTF-8"
LC_MONETARY="es_MX.UTF-8"
LC_MESSAGES="es_MX.UTF-8"
LC_PAPER="es_MX.UTF-8"
LC_NAME="es_MX.UTF-8"
LC_ADDRESS="es_MX.UTF-8"
LC_TELEPHONE="es_MX.UTF-8"
LC_MEASUREMENT="es_MX.UTF-8"
LC_IDENTIFICATION="es_MX.UTF-8"
LC_ALL=

locale -a

C
es_MX.utf8
POSIX

* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with xfce4.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with xfce4.
* AUR contributor.

Offline

#6 2012-10-02 15:23:14

karol
Archivist
Registered: 2009-05-06
Posts: 25,433

Re: [SOLVED] Decimal separator is incorrect for es_MX

Your locale settings look OK, seems it's the bug DSpider was pointing to: https://bugs.launchpad.net/ubuntu/+sour … bug/995243

Offline

#7 2012-10-02 15:29:22

Joel
Member
From: Tijuana, BC, México
Registered: 2011-12-21
Posts: 84

Re: [SOLVED] Decimal separator is incorrect for es_MX

Yes, but I found a solution here: http://www.ubuntu-es.org/node/167684#.UGsGSbRH-jg

1.- Needed to edit the file: /usr/share/i18n/locales/es_MX
2.- Look for the line:

LC_NUMERIC
copy "es_ES"
END LC_NUMERIC

3.- Change that line to:

LC_NUMERIC
decimal_point "<U002E>"
thousands_sep "<U002C>"
grouping 3;3
END LC_NUMERIC

3.- Later I run:

locale-gen

4.- Now, works as expected smile

Maybe, the Arch dev can patch this file for the new and fresh installations


* PC: Intel Core 2 DUO E6550 @ 2.33 GHz with 2 GB RAM: Archlinux-i686 with xfce4.
* Laptop: Intel Core 2 DUO T6600 @ 2.20 GHz with 4 GB RAM: Archlinux-x86-64 with xfce4.
* AUR contributor.

Offline

#8 2012-10-02 16:44:01

GogglesGuy
Member
From: Rocket City
Registered: 2005-03-29
Posts: 605
Website

Re: [SOLVED] Decimal separator is incorrect for es_MX

Joel wrote:

Maybe, the Arch dev can patch this file for the new and fresh installations

That won't happen, this needs to be fixed upstream.

Offline

#9 2012-10-02 16:46:28

DSpider
Member
From: Romania
Registered: 2009-08-23
Posts: 2,273

Re: [SOLVED] Decimal separator is incorrect for es_MX

Good job.

Don't forget to mark it as solved (by editing the first post) so that other people (including yourself sometimes) may find useful.


By the way, pacman says that it belongs to glibc, so look out for updates to the glibc package, because it will rewrite that file.

$ pacman -Qo /usr/share/i18n/locales/es_MX 
/usr/share/i18n/locales/es_MX is owned by glibc 2.16.0-4

Last edited by DSpider (2012-10-02 16:47:11)


"How to Succeed with Linux"

I have made a personal commitment not to reply in topics that start with a lowercase letter. Proper grammar and punctuation is a sign of respect, and if you do not show any, you will NOT receive any help (at least not from me).

Offline

Board footer

Powered by FluxBB