keymap fr/oss: numpad '.' mapped to period instead of KP_Decimal

Reported by Olivier Mengué on 2008-02-02
48
This bug affects 4 people
Affects Status Importance Assigned to Milestone
xkeyboard-config
Fix Released
Medium
Ubuntu
Undecided
Unassigned
xkeyboard-config (Ubuntu)
Medium
Unassigned

Bug Description

Binary package hint: xserver-xorg-input-kbd

In Ubuntu 7.10, xserver-xorg-input-kbd_1.2.0-1+1.2.1ubuntu1 with the following Xorg.conf settings:

Section "InputDevice"
        Identifier "Generic Keyboard"
        Driver "kbd"
        Option "CoreKeyboard"
        Option "XkbRules" "xorg"
        Option "XkbModel" "pc105"
        Option "XkbLayout" "fr"
        Option "XkbVariant" "oss"
EndSection

Got:
$ xmodmap -pke | grep 'keycode *91'
keycode 91 = KP_Delete period comma U202F comma U202F

Expected:
$ xmodmap -pke | grep 'keycode *91'
keycode 91 = KP_Delete KP_Decimal comma U202F comma U202F

This issue is a MAJOR usability issue in OpenOffice.org Calc, as in the current state Calc is unusable to enter decimal numbers quickly.
This is a major blocker for migration of Windows/Excel users to Ubuntu/OpenOffice.org. See bug #188331.

Olivier Mengué (dolmen) wrote :

The file to fix is probably /usr/share/X11/xkb/symbols/fr, lines 389 to 391:

< // French uses a comma as decimal separator, but keyboards are labeled with a period
< // Will take effect when KP_Decimal is mapped to the locale decimal separator
< key <KPDL> { [ KP_Delete, period, KP_Delete, KP_Decimal ] };

> key <KPDL> { [ KP_Delete, KP_Decimal, KP_Delete, KP_Decimal ] };

Olivier Mengué (dolmen) wrote :

Voici le paliatif.

Créez le fichier $HOME/.Xmodmap contenant les lignes suivantes :
! Correctif pour le bug 188342
! https://bugs.launchpad.net/ubuntu/+bug/188342
keycode 91 = KP_Delete KP_Decimal KP_Separator U202F KP_Separator U202F

Sebastien Bacher (seb128) wrote :

The comment indicates that's an upstream choice and not a bug

upstream choice? Who made that one? Ubuntu? It is just a bad choice IMHO. Things work with other distros like debian or gentoo (I did not test others).

Olivier Mengué (dolmen) wrote :

This upstream choice is breaking a major application (OOo). Nicolas Mailhot seems to be the upstream maintainer of this keymap.

Sebastien Bacher (seb128) wrote :

Things are not likely different in debian, the ubuntu xkeyboard-config is the debian version

You are right, my comment was stupid.

Olivier Mengué (dolmen) wrote :

When I was talking about "upstream", I was thinking to X.org, not Debian. I understand this is not the usual meaning of "upstream" here.
The "oss" alternative of the fr keymap is broken in Ubuntu because it is broken in Debian because it is broken in X.org.

Colin Watson (cjwatson) wrote :

As a workaround, you could choose to use the plain fr layout, without the oss variant. System -> Preferences -> Keyboard -> Layouts.

Fred (frederic-lespez) wrote :

I can confirm this bug in OpenOffice.org Calc and Gnucash.
The following workaround from Olivier Mengué works like a charm :
https://bugs.launchpad.net/ubuntu/+source/xkeyboard-config/+bug/188342/comments/2

I don't know if the workaround from Colin Watson works or not... But in Gnucash, numpad '.' doesn't work at all either with "French alternative" or "French" layout. See https://bugs.launchpad.net/gnucash/+bug/157968

It is a really annoying bug. It should work out of the box since this kind of thing drives users away instantly.

And yes indeed, "French uses a comma as decimal separator, but keyboards are labeled with a period". Neverless all french users expect that their numpad '.' gives a comma. And that's what happens in the "Windows" world. So give it to us, please ;-)

Rolf Leggewie (r0lf) on 2008-07-06
Changed in xkeyboard-config:
status: New → Triaged
Changed in xkeyboard-config:
importance: Undecided → Medium

From a Ubuntu bug:
https://bugs.edge.launchpad.net/ubuntu/+source/xkeyboard-config/+bug/188342

[Problem]
It sounds like there is no good solution for handling KPDL, but we're getting some pushback from french users who would like the default switched to be KP_Decimal rather than period on fr keyboards.

Is this something that would be reasonable to consider changing?

[Original Report]
In Ubuntu 7.10, xserver-xorg-input-kbd_1.2.0-1+1.2.1ubuntu1 with the following Xorg.conf settings:

Section "InputDevice"
        Identifier "Generic Keyboard"
        Driver "kbd"
        Option "CoreKeyboard"
        Option "XkbRules" "xorg"
        Option "XkbModel" "pc105"
        Option "XkbLayout" "fr"
        Option "XkbVariant" "oss"
EndSection

Got:
$ xmodmap -pke | grep 'keycode *91'
keycode 91 = KP_Delete period comma U202F comma U202F

Expected:
$ xmodmap -pke | grep 'keycode *91'
keycode 91 = KP_Delete KP_Decimal comma U202F comma U202F

This issue is a MAJOR usability issue in OpenOffice.org Calc, as in the current state Calc is unusable to enter decimal numbers quickly.
This is a major blocker for migration of Windows/Excel users to Ubuntu/OpenOffice.org. See bug #188331.

(Another reporter adds "And yes indeed, "French uses a comma as decimal separator, but keyboards are labeled with a period". Neverless all french users expect that their numpad '.' gives a comma. And that's what happens in the "Windows" world. So give it to us, please ;-)" )

The file to fix is probably /usr/share/X11/xkb/symbols/fr, lines 389 to 391:

< // French uses a comma as decimal separator, but keyboards are labeled with a period
< // Will take effect when KP_Decimal is mapped to the locale decimal separator
< key <KPDL> { [ KP_Delete, period, KP_Delete, KP_Decimal ] };

> key <KPDL> { [ KP_Delete, KP_Decimal, KP_Delete, KP_Decimal ] };

My one concern here is that this may be one of those changes that some people will like, and some people will dislike. But not being French I can make no guesses about what the majority would prefer.

I've gone ahead and forwarded this upstream for further consideration at https://bugs.freedesktop.org/show_bug.cgi?id=19756 . In Ubuntu we'll stick with whatever upstream deems to be the correct approach, so if you'd really like it changed, I'd encourage you to subscribe to the upstream bug and share your thoughts on the matter.

Changed in xkeyboard-config:
status: Unknown → Confirmed

Fixed. In case of troubles - I'll send the wrath of French users on you;)

Changed in xkeyboard-config:
status: Confirmed → Fix Released

Fixed in xkeyboard-config 1.5 now in Jaunty.

Changed in xkeyboard-config:
status: Triaged → Fix Released
Xwang (xwang1976) wrote :

I've a very similar problem using the Italian language on my kubuntu 9.04 amd64 system.
Openoffice and gnucash work correctly (they see the decimal separator of the keypad like a comma as prescrived by the current locale), but speedcrunch, kate, firefox, thunderbird and a lot of other programs see the decimal separator like a dot.
Shouldn't the KP_Decimal value be aligned with the locale settings?
This is the output of xmodmap -pke for this key:
keycode 91 = KP_Delete KP_Decimal KP_Delete KP_Decimal KP_Delete KP_Decimal
Thank you,
Xwang

Changed in xkeyboard-config:
importance: Unknown → Medium
Changed in xkeyboard-config:
importance: Medium → Unknown
Changed in xkeyboard-config:
importance: Unknown → Medium
Olivier Mengué (dolmen) wrote :

The "fr/oss" keyboard still has the bug in Ubuntu 11.10. And this is still a major usability issue for LibreOffice Calc users.

/usr/share/X11/xkb/symbols/fr in the oss section includes keypad(oss) which includes kpdl(dotoss):

partial keypad_keys
xkb_symbols "dotoss" {

    key.type[Group1]="FOUR_LEVEL_MIXED_KEYPAD" ;

    key <KPDL> { [ KP_Delete, period, comma, 0x100202F ] }; // <delete> . , ⍽ (narrow no-break space)
};

summary: - keymap fr: numpad '.' mapped to period instead of KP_Decimal
+ keymap fr/oss: numpad '.' mapped to period instead of KP_Decimal
mohican (mohican) wrote :

Bug still there on libreoffice 3.5.3 and Ubuntu 12.04.
and this time it seems that the workaround using legacy keyboard configuration does not work anymore.

As the status of this bug is "fix released" there is no chance that it will be reopened unless we do something.

How can we change the status ? Or should we create a new one ?

I don't see this bug anymore.

mohican (mohican) wrote :

My config :
Ubuntu 12.04 64 bits and 32 bits.
Keyboard = français (variante) (default choice at install time)
 LibreOffice 3.5.3.2

In Calc, numeric key '.' inputs dot instead of comma (french numerical separator)

Ok, not the same keyboard: français (variante obsolète), but even with the same keyboard layout as you have, I still get a comma.

mohican (mohican) wrote :

So, it works also for me with the français (variante obsolète).

In order to change really from one keyboard to the other you have to keep only one keyboard layout in the list.

Try this in the keyboard layout dialog :
- add français (variante)
-delete français (variante obsolète)
Then log out and log in again
Then try Calc

mohican (mohican) wrote :

Here is a solution for the keyboard layout "français (variante)" with Ubuntu 12.04 (found on the french forum), it is different from the solution used up to 11.10 :

In the keyboard layout parameter tool, go to
Options > disposition du pavé numérique > cocher "obsolète"

Things work for me out of the box, no need to check any box.

mohican (mohican) wrote :

Good for you. But several (lots ?) of french people still affected :
http://forum.ubuntu-fr.org/viewtopic.php?pid=9353481

mohican (mohican) wrote :

Interesting to note :
applying the solution in post #23, the numeric keypad will input a comma in LibreOffice
but still a dot in other applications (such as gedit, thunderbird, Wine notepad)

Lo_pescofi (corbieres) wrote :

On Ubuntu 12.04(x64) with french keyboard :
By défault the Delete key (.,) of keypad is interpreted like "point" (.). Is uncomfortable when use mathematical application like LibreOffice Calc.
For change, to haveDelete key (.,) of keypad is interpreted like decimal séparator. You need to change keyboard options like this:

System Parameter (ubuntu) \ Keyboard \ layout parameter
1)
=> Layout keypad "Obsolete"
=> Behavior of the "Del" key: "Default"
2) LibreOfffice Calc:
Decimal separator key: Same as the language setting checked (,)

The name of "Obsolète"is inappropriate !
--------------------------------------------------------------------
In french :
Sur Ubuntu 12.04(x64) avec clavier français (variante) :
Par défault la touche Suppr (.,) du clavier numérique est interprété comme un point(.) . C'est relativement inconfortable pour les application numérique telles que libreOffice Calc.

Pour que la touche Suppr (.,) du clavier numérique soit interprétée comme un séparateur décimal. Il faut modifier les options du clavier comme ceci :
1) Paramètre système (ubuntu) \ clavier \ paramètre d'agencement
=> Disposition du pavé numérique "Obsolète"
=> Comportement de la touche "Suppr": "Par défaut"
2) Calc:
Touche séparateur de décimales: coché Identique au paramètre linguistique (,)

mohican (mohican) wrote :

the keyboard layout which as this problem is "français (variante)" =? "français oss"
it is the one installed by default for most french keyboards in France.

there is no problem with the layout "français"
and the layout "français (obsolète)" =? "français latin9"

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.