Sway wont let me change keyboard layouts

No it is not working, waybar also shows (English (US)) as keyboard layout

1 Like

Okay! Maybe we should set the X11 layout try

setxkbmap -layout hu

May not be installed! Install

xorg-setxkbmap

Here is what system post I got (with sudo privilages)

setxkbmap -layout hu
Authorization required, but no authorization protocol specified
Cannot open display “:0”

xorg-setxkbmap is being reinstalled

1 Like

I apologise for all your trouble these problems never appereas in out testing

Add an -E before sudo

So


sudo -E etc...

Edit : Does setaxmpd need to run as root?

Here is what I got after sudo -E

sudo -E setxkbmap -layout hu
Authorization required, but no authorization protocol specified
Cannot open display ":0

1 Like

It does not need root at all I beleive…try without sudo or -E

If that doesnt work

xhost +

Then do it.

Without sudo i just setxkbmap -layout hu
Nothing changed

and xhos + post the following
xhost +
access control disabled, clients can connect from any host

1 Like

Yeh after typing xhost +

Try the setxkbmap again

@obitron Are you in a VM?

No I am Not in a VM

Nothing changed after xhost +

I did a setxkbmap -layout hu (nothing changed) added sudo -E then setxkbmap (still nothing)

Run a localectl status (stiill the same)
System Locale: LANG=hu_HU.UTF-8
VC Keymap: hu
X11 Layout: us

Try

localectl set-keymap --no-convert hu

Edit : @obitron why dont you reboot once too

I have run it with and without root privilege
When running it as user nothing change (even after reloading swayconfig with swaymsg reload)
When running it as a root user got the following error

00:00:00.012 [swaymsg/main.c:417] Unable to retrieve socket path

1 Like

I did reboot still the same.

1 Like

Okay right! That could be your problem definetly. However that problem should not occur unless you are in a tty. :thinking:

This the only thing I can think of now. I’m stuck.
More clever people! Please come!

Sway socket not detected

Using a swaymsg argument, such as swaymsg -t get_outputs, will sometimes return the message:

sway socket not detected. ERROR: Unable to connect to

when run inside a terminal multiplexer (such as gnu screen or tmux). This means swaymsg could not connect to the socket provided in your SWAYSOCK.

To view what the current value of SWAYSOCK is, type:

$ env | fgrep SWAYSOCK SWAYSOCK=/run/user/1000/sway-ipc.1000.4981.sock

To work around this problem, you may try attaching to a socket based on the running sway process:

$ export SWAYSOCK=/run/user/$(id -u)/sway-ipc.$(id -u).$(pgrep -x sway).sock

Yeh @obitron I have nothing more. I’m very sorry. A bad first experience but I can’t think of anything more. Thank you for being patient with me and I’m sorry to see you face these problems.

Your X11 layout is not setting! And I can’t think why too. Your layout is not setting in your locale and I can’t think why…

Run it and i got the following grep: SWAYSOCK=/run/user/1000/sway-ipc.1000.4981.sock: No file and directory found

I did run this export SWAYSOCK=/run/user/$(id -u)/sway-ipc.$(id -u).$(pgrep -x sway).sock with root privilege no error but nothing changed

Bring here the other devs (or more experienced people) we figure it out somehow. If not today then tomorrow, if not tomorrow then sometime.

1 Like

Hmmm…Your missing files.

Try a full system update once.

Edit : I can’t reproduce that. Hmm…

I have run sudo pacman -Syyuu (did a full update)

I even added Chaotic aur for the right files ( like xorg-setxkbmap) still nothing

1 Like

Why are we seeing so many posts about adding chaotic aur causing system files to go missing?

2 Likes