You are not logged in.

#1 2017-09-05 11:45:20

dockland
Member
From: Sweden
Registered: 2015-06-06
Posts: 861

[SOLVED] Setting keymap xterm

Just finishing up a brand new ArchLinux install (2017.09.01 iso) along with i3 on one of my Intel NUC's (NUC7i7BNH) with a Cherry JK-03 keyboard with swedish keys (åäö). I decided to go with xterm instead of xfce4-terminal on this install. Keyboard layout is set to sv-latin1 and works great in TTY, but when starting X and xterm i dont have swedish keyboard layout.

localectl status
System Locale: LANG=en_US.UTF-8
VC Keymap: sv-latin1
X11 Layout: n/a

/etc/vconsole.conf

KEYMAP=sv-latin1

Tried "KEYMAP=sv" aswell without success.

I have tried localectl set-keymap --no-convert sv-latin1 without error messages, but still no swedish characters in xterm.

(If it's that simple that i have to run xrdb ~/.Xresources i would appreciate if anyone knows where tilde (~) is located on default US keyboard. I have searched but the suggestions doesn't work for my keyboard.)

Last edited by dockland (2017-09-05 17:10:55)


I possess a device, in my pocket, that is capable of accessing the entirety of information known to man.
I use it to look at funny pictures of cats and to argue with strangers.

Offline

#2 2017-09-05 11:50:31

Slithery
Administrator
From: Norfolk, UK
Registered: 2013-12-01
Posts: 5,776

Re: [SOLVED] Setting keymap xterm

dockland wrote:

(If it's that simple that i have to run xrdb ~/.Xresources i would appreciate if anyone knows where tilde (~) is located on default US keyboard).

Um, just manually expand the tilda...

xrdb /home/dockland/.Xresources

No, it didn't "fix" anything. It just shifted the brokeness one space to the right. - jasonwryan
Closing -- for deletion; Banning -- for muppetry. - jasonwryan

aur - dotfiles

Offline

#3 2017-09-05 11:56:41

ayekat
Member
Registered: 2011-01-17
Posts: 1,634

Re: [SOLVED] Setting keymap xterm

/etc/vconsole.conf only configures the TTY behaviour. You need to configure the X keyboard layout separately. Xresources has nothing to do with this, AFAIK.

Have you read https://wiki.archlinux.org/index.php/Ke … on_in_Xorg?


pkgs │ hacks │ cfg │ blag

Offline

#4 2017-09-05 12:28:13

dockland
Member
From: Sweden
Registered: 2015-06-06
Posts: 861

Re: [SOLVED] Setting keymap xterm

Yes, haha, of course. Works but keymap is still US layout. I think i've missed something very very basic.
I do have a ~/.Xresources

Xterm.termname: xterm-256color
Xterm.vt100.locale: true
Xterm.vt100.metaSendsEscape: true
Xterm.vt100.saveLines: 10000
Xterm.vt100.selectToClipboard: true
Xterm.vt100.reverseVideo: true

but it doesn't generate any changes, for example, background is still white and text is black. I've rebooted between any changes, just to be sure everything is loaded from scratch.


I possess a device, in my pocket, that is capable of accessing the entirety of information known to man.
I use it to look at funny pictures of cats and to argue with strangers.

Offline

#5 2017-09-05 12:30:28

dockland
Member
From: Sweden
Registered: 2015-06-06
Posts: 861

Re: [SOLVED] Setting keymap xterm

ayekat wrote:

/etc/vconsole.conf only configures the TTY behaviour. You need to configure the X keyboard layout separately. Xresources has nothing to do with this, AFAIK.

Have you read https://wiki.archlinux.org/index.php/Ke … on_in_Xorg?

Yes, but only the "Using localectl" part. As the "localectl set-keymap --no-convert sv-latin1" command in my first post.


I possess a device, in my pocket, that is capable of accessing the entirety of information known to man.
I use it to look at funny pictures of cats and to argue with strangers.

Offline

#6 2017-09-05 12:51:00

ayekat
Member
Registered: 2011-01-17
Posts: 1,634

Re: [SOLVED] Setting keymap xterm

Have you checked whether /etc/X11/xorg.conf.d/00-keyboard.conf was correctly generated?
Also, have you restarted X after generating that file?

Alternatively, does it work if you use setxkbmap?


pkgs │ hacks │ cfg │ blag

Offline

#7 2017-09-05 13:37:38

dockland
Member
From: Sweden
Registered: 2015-06-06
Posts: 861

Re: [SOLVED] Setting keymap xterm

I checked, the /etc/X11/xorg.conf.d is empty.
I forgot to do Xorg :0 -configure (as root) that generates a skeleton as per the wiki, but got a segmentation fault, and my xorg log was empty. I'm going to install lightdm, greeter and xfce4 to be able to troubleshoot on the same computer.


I possess a device, in my pocket, that is capable of accessing the entirety of information known to man.
I use it to look at funny pictures of cats and to argue with strangers.

Offline

#8 2017-09-05 14:52:59

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 78,877

Re: [SOLVED] Setting keymap xterm

Forget about Xorg -configure.
/etc/X11/xorg.conf.d/11-keyboard.conf

Section "InputClass"
    Identifier          "Keyboard Defaults"
    MatchIsKeyboard     "yes"
    Option              "XkbLayout" "sv" # what you apparently want
    Option              "XkbOptions" "terminate:ctrl_alt_bksp,compose:caps" # handy ;-)
EndSection

Check "man xorg.conf" for other options, you probably need to pick the proper variant and stuff.

Offline

#9 2017-09-05 15:17:32

dockland
Member
From: Sweden
Registered: 2015-06-06
Posts: 861

Re: [SOLVED] Setting keymap xterm

seth wrote:

Forget about Xorg -configure.
/etc/X11/xorg.conf.d/11-keyboard.conf

Section "InputClass"
    Identifier          "Keyboard Defaults"
    MatchIsKeyboard     "yes"
    Option              "XkbLayout" "sv" # what you apparently want
    Option              "XkbOptions" "terminate:ctrl_alt_bksp,compose:caps" # handy ;-)
EndSection

Check "man xorg.conf" for other options, you probably need to pick the proper variant and stuff.

Ok, thanks. What is wrong with "Xorg -configure" due to it's still in the wiki?


I possess a device, in my pocket, that is capable of accessing the entirety of information known to man.
I use it to look at funny pictures of cats and to argue with strangers.

Offline

#10 2017-09-05 15:25:50

seth
Member
From: Won't reply 2 private help req
Registered: 2012-09-03
Posts: 78,877

Re: [SOLVED] Setting keymap xterm

It's broken for ages - to the degree where I doubt this is a "bug" bug.
In general, static configs as produced by that command are deprecated and discouraged for nearly a decade.

Offline

#11 2017-09-05 17:10:39

dockland
Member
From: Sweden
Registered: 2015-06-06
Posts: 861

Re: [SOLVED] Setting keymap xterm

Ok, thanks. setxkbmap worked fine. Marking thread as solved.


I possess a device, in my pocket, that is capable of accessing the entirety of information known to man.
I use it to look at funny pictures of cats and to argue with strangers.

Offline

Board footer

Powered by FluxBB