You are not logged in.

#1 2019-09-22 01:03:04

wenbushi
Member
Registered: 2016-11-10
Posts: 14

How to load xkeymap at user login or start up?

I changed my keyboard mapping recently followed archwiki. But

xkbcomp custom.xkb $DISPLAY

in ~/.xinitrc, ~/.bashrc or ~/.pofile doesn't take effect at user login. So how to load the keymap automatically at user login or start up?

Last edited by wenbushi (2019-09-22 01:23:47)

Offline

#2 2019-09-22 03:00:47

jasonwryan
Anarchist
From: .nz
Registered: 2009-05-09
Posts: 30,426
Website

Re: How to load xkeymap at user login or start up?

Paste the .xinitrc with the invocation you are trying to implement.


Arch + dwm   •   Mercurial repos  •   Surfraw

Registered Linux User #482438

Offline

#3 2019-09-22 07:41:18

wenbushi
Member
Registered: 2016-11-10
Posts: 14

Re: How to load xkeymap at user login or start up?

Just one line follows the wiki:

test -f ~/.Xkeymap && xkbcomp ~/.Xkeymap $DISPLAY

where ~/.Xkeymap is a symbolic link to my custom key mapping file.

I can load it manually from bash after login.

Last edited by wenbushi (2019-09-22 07:43:34)

Offline

#4 2019-09-22 07:48:29

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

Re: How to load xkeymap at user login or start up?

Post the entire ~/.xinitrc, as Jason asked.


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

#5 2019-09-22 09:11:49

wenbushi
Member
Registered: 2016-11-10
Posts: 14

Re: How to load xkeymap at user login or start up?

Slithery wrote:

Post the entire ~/.xinitrc, as Jason asked.

Sorry if I didn't make it clear.

The entire content of my ~/.xinitrc is that line.

$ cat ~/.xinitrc 
test -f ~/.Xkeymap && xkbcomp ~/.Xkeymap $DISPLAY

Offline

#6 2019-09-22 09:20:24

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

Re: How to load xkeymap at user login or start up?

You're obviously not launching your DE/WM using startx as that file is garbage and won't do anything.

How do you log in to your graphical session?


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

#7 2019-09-22 16:34:40

wenbushi
Member
Registered: 2016-11-10
Posts: 14

Re: How to load xkeymap at user login or start up?

Slithery wrote:

You're obviously not launching your DE/WM using startx as that file is garbage and won't do anything.

How do you log in to your graphical session?

No. I'm using sddm to log into KDE and there is no speicial configurations as I remember. But there must be something wrong with the command above,

because I put it in many start up scripts like ~/.xprofile and ~/.xinitrc, and I'm sure the line was executed during login(I've tested it).

But I can load it manually without warnings or errors after that.

Last edited by wenbushi (2019-09-22 17:08:32)

Offline

#8 2019-09-22 16:36:52

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

Online

Board footer

Powered by FluxBB