You are not logged in.

#1 2023-12-16 17:26:43

xyrgug
Member
Registered: 2023-12-15
Posts: 34

[SOLVED] colemak-dh capslock backspace problem to make it persistent

In this layout, caps lock has been replaced by backspace. But if you hold it, it removes only one character.
This is a common problem and it is usually suggested to solve it with this command

xset r 66

The problem is that this is valid until the next reboot.

Then I kinda looked at wiki and it suggests using the xorg-xinit package.
So I created ~/.xinitrc and put this line at the beginning. 

#!/bin/sh
xset r 66

userresources=$HOME/.Xresources
usermodmap=$HOME/.Xmodmap
sysresources=/etc/X11/xinit/.Xresources
sysmodmap=/etc/X11/xinit/.Xmodmap

...
...

It didn't work.

startx "/usr/bin/xset r 66"

Didn't work either.

Last edited by xyrgug (2023-12-16 21:54:21)

Offline

#2 2023-12-16 19:02:07

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

Re: [SOLVED] colemak-dh capslock backspace problem to make it persistent

Probably not, at least not unless you start the session w/ xinit or startx and certainly not if the xset call is followed by some setxkbmap call.

loginctl session-status

Offline

#3 2023-12-16 19:54:53

xyrgug
Member
Registered: 2023-12-15
Posts: 34

Re: [SOLVED] colemak-dh capslock backspace problem to make it persistent

Sorry, did I understand correctly that I need to insert these three lines at the end of the file

xscreensaver &
exec openbox-session
startx "/usr/bin/xset r 66"

to make it look like this?

...
# start some nice programs

if [ -d /etc/X11/xinit/xinitrc.d ] ; then
 for f in /etc/X11/xinit/xinitrc.d/?*.sh ; do
  [ -x "$f" ] && . "$f"
 done
 unset f
fi

twm &
xclock -geometry 50x50-1+1 &
xterm -geometry 80x50+494+51 &
xterm -geometry 80x20+494-0 &
exec xterm -geometry 80x66+0+0 -name login

xscreensaver &
exec openbox-session
startx "/usr/bin/xset r 66"

The output of

loginctl session-status

is

[haal@dragon ~]$ loginctl session-status
2 - haal (1000)
  Since: Sat 2023-12-16 21:37:25 MSK; 55min ago
  State: active
 Leader: 2960 (sddm-helper)
   Seat: seat0; vc2
    TTY: tty2
 Remote: no
Service: sddm
   Type: x11
  Class: user
Desktop: KDE
   Idle: no
   Unit: session-2.scope
         ├─2960 /usr/lib/sddm/sddm-helper --socket /tmp/sddm-auth-6bbeb896-2dc7-48cf-bb13-9bb3ee03c802 -
-id 1 --start /usr/bin/startplasma-x11 --user haal
         ├─2976 /usr/bin/kwalletd5 --pam-login 12 15
         └─2977 /usr/bin/startplasma-x11

Dec 16 21:37:26 dragon systemd[1]: Started Session 2 of User haal.

Offline

#4 2023-12-16 20:09:56

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

Re: [SOLVED] colemak-dh capslock backspace problem to make it persistent

No, that's complete nonsense and also you're starting the session via SDDM, the xinitrc has absolutely no part in this.

Try to use ~/.xprofile, https://wiki.archlinux.org/title/Xprofile
But if you're setting the layout via the KDE settings, that's probably too early and you'd use something like

(sleep 10; xset r 66) &

Offline

#5 2023-12-16 21:48:40

xyrgug
Member
Registered: 2023-12-15
Posts: 34

Re: [SOLVED] colemak-dh capslock backspace problem to make it persistent

Okay.
First I installed yay
Then I installed

yay -S xprofile

Then I created ~/.xprofile
and added this line

(sleep 10; xset r 66) &

And it have worked.
Thank you, you've been a great help. Because I was getting so tired of manually typing xset r 66 in every time.

Last edited by xyrgug (2023-12-16 21:58:44)

Offline

#6 2023-12-17 08:36:56

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

Re: [SOLVED] colemak-dh capslock backspace problem to make it persistent

https://aur.archlinux.org/packages/xprofile is completely unrelated and just randomly named likewise - you can remove that package.

Offline

#7 2023-12-17 12:24:03

xyrgug
Member
Registered: 2023-12-15
Posts: 34

Re: [SOLVED] colemak-dh capslock backspace problem to make it persistent

Removed the package and indeed everything continues to work.
Thanks again for your help. I hope those who have a similar problem will find this thread useful.

Offline

Board footer

Powered by FluxBB