22

The German decimal mark standard is a comma (e.g. 1.400,50 one-thousand-fourhundred-euro-and-fifty-cent).

Most apps use the US standard period. Is there a way to quickly switch the comma to a period on the numeric keypad (and back)?

enter image description here

6 Answers 6

29

In Ubuntu 18.04 I couldn't find any appropriate option in "standard" settings (neither in Devices -> Keyboard, nor in Region & Language).

The "clickable" solution I found uses gnome-tweak-tool that I had previously installed for other reasons: sudo apt install gnome-tweak-tool

To run the tool hit Win button and type Tweaks.

In the app in Keyboard & Mouse tab click Additional Layout Options and open the Numeric keypad Delete behavior section. Multiple of the available options there worked for me (I have selected Four-level key with dot as my default).

The nice thing with this solution is that the change is applied instantly as you select the option (no need to click apply or anything). This might be useful if you need to change temporarily to do something and go back to default - just leave the app open do your thing and click back when you are done.

5
  • I'm wondering what "Four-level key" refers to, but it may be because AltGr+NumDel gives you the dot again, while Shift+AltGr+NumDel gives you a narrow no-break space (u+202f). Rad! Mar 1, 2020 at 17:37
  • That's exactly the point: this settings makes the Numeric Keypad Delete a "Four-level key", so you can use level modifiers keys (Shift and Alt-Gr) to switch between 4 possible options, as described in help.ubuntu.com/community/… . This means you can set it to use Alt-Gr to insert a period or a comma.
    – gerlos
    Oct 29, 2020 at 10:19
  • For confused potatoes like me, the "Delete" key is the same key where "." is.
    – Klesun
    Dec 17, 2021 at 12:09
  • @Klesun It's the key where the . or , is on the numeric keypad, the one marked with the orange square by OP in the image. On my physical keyboard it is marked with . and Del. In the OP's German layout image it is marked with , and Del.
    – jarzec
    Dec 19, 2021 at 18:52
  • This didn't work for me, running 22.04
    – Glubbdrubb
    Apr 19 at 8:10
6

There is an implemented option for kpdl(dot):

setxkbmap de -option kpdl:dot

for permanent changes add the option to /etc/default/keyboard

# KEYBOARD CONFIGURATION FILE

XKBMODEL="pc105"
XKBLAYOUT="de"
XKBVARIANT=""
XKBOPTIONS="kpdl:dot"

BACKSPACE="guess"

This way it will be independent from your xkb-data and safe on dist upgrade.

1
0

One way is to create a custom keyboard layout.

In /usr/share/X11/xkb/symbols/de, add this:

partial alphanumeric_keys
xkb_symbols "dot" {
    include "de(basic)"
    include "kpdl(dot)"
    name[Group1]="German (dot as decimal separator)";
};

In /usr/share/X11/xkb/rules/evdev.xml, add this:

        <variant>
          <configItem>
            <name>dot</name>
            <description>German (dot as decimal separator)</description>
          </configItem>
        </variant>

After next reboot you'll be able to add the German (dot as decimal separator) layout and then switch easily between that layout and German.

0

In Ubuntu 20.04 this can be achieved with gnome-tweaks.

To install gnome-tweaks, type in a terminal:

sudo apt install gnome-tweaks

or without a terminal:

  • Press the 'Win' button, or click on 'Activities'
  • Type 'Ubuntu Software' and hit 'enter' or click on 'Ubuntu Software'
  • Type 'gnome-tweaks'
  • Select the 'Tweaks' software package
  • Click on 'Install'

To run the tool, type in a terminal:

gnome-tweaks

or without a terminal

  • Press the 'Win' button, or click on 'Activities',

  • type 'Tweaks' and hit enter

  • Click on 'Keyboard & Mouse'

  • Click on 'Additional Layout Options'

  • Click on 'Numeric keypad Delete behavior'

  • Click on 'Four-level key with dot'

Now the ',' key behaves as it was a '.' key. If you need the ',' you can hold the 'alt gr' key and press ','.

You can also choose 'Legacy key with dot', and later change it back to 'Disabled' or 'Legacy key with comma'.

For people with a US international keyboard with a '.' on the numeric pad, but regularly need a ','. Select 'Four-level key with dot' if you more often need a '.', or 'Four-level key with comma' if you more often need the ','.

0

As I couldn't google a way to do it for the Mate desktop: for Mate 1.24.1 start Keyboard Preferences, select Layouts and the button "Options". Below "Layout of numeric keypad" there is an entry called "Legacy" which changes the comma to a dot. That's the only thing it seems to change.

-1

Here are some ways to change it. In may case it works with Keyboard settings > Layout > Options. There is option for numeric Del button. Found myself easy.

Other way with xmodmap. I don't like it.

Both ways are here from awesome guys: https://ubuntuforums.org/showthread.php?t=1377642

2
  • Please don't post links as answer. Reproduce the procedure here in your answer. If the URL dies your answer would be useless.
    – derHugo
    Nov 8, 2017 at 16:40
  • 1
    Welcome to Ask Ubuntu! A link to a potential solution is always welcome, but please add context around the link so your fellow users will have some idea what it is and why it's there. Always quote the most relevant part of an important link, in case the target site is unreachable or goes permanently offline. Take into account that being barely more than a link to an external site is a possible reason as to Why and how are some answers deleted?.
    – Videonauth
    Nov 8, 2017 at 17:45

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .