Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Keyboard switching #532

Closed
ghost opened this issue Mar 22, 2016 · 11 comments
Closed

Keyboard switching #532

ghost opened this issue Mar 22, 2016 · 11 comments

Comments

@ghost
Copy link

ghost commented Mar 22, 2016

language
I run all this commands in console, but i can switch keyboard language yet.
In i3 I use setxkbmap like this setxkbmap -model logitechdinovoedge -layout us,ru -option grp:alt_shift_toggle
What I doing wrong? Which is difference with setxkbmap and XKB.Please help me. I have been registered in Github for this.

@progandy
Copy link
Contributor

You have to set the xbk definitions before starting sway. The following settings work for me.

export XKB_DEFAULT_LAYOUT=de,us
export XKB_DEFAULT_OPTIONS=grp:alt_shift_toggle
sway

@ghost
Copy link
Author

ghost commented Mar 22, 2016

Thank you. Спасибо.
I wrote alias in my zshrc
alias swaywm='export XKB_DEFAULT_LAYOUT=ru,us && export XKB_DEFAULT_OPTION=grp:alt_shift_toggle && sway -d 2> ~/sway.log'
Please write me if I doing something wrong again.

@kigerpunk
Copy link

@VasilPupkin Sorry that this is off-topic, but are Rennaissance waifus a thing?

@ghost
Copy link
Author

ghost commented Apr 21, 2016

Sorry, I dont check my git acc yet. I dont understand what mean "Rennaissance", because  im from Russia and I learn english now in school. I just choose arch-tan picture for wallpaper. If you want to know my favorite anime girl is Azusa from K-ON, lol.

@riquito
Copy link

riquito commented Sep 5, 2017

@cafehaine thanks for redirecting me here but it doesn't seem to help with my problem.
I cannot understand how to change the keyboard layout from inside a running sway (I usually change keyboard layouts to write in different languages to different people. Killing and restarting sway is not exactly the solution I was hoping for). If it isn't supported I'll open a feature request

@cafehaine
Copy link

export XKB_DEFAULT_LAYOUT=de,us
export XKB_DEFAULT_OPTIONS=grp:alt_shift_toggle
sway

then press alt and shift to switch layouts

There is now way to do it programmatically

@riquito
Copy link

riquito commented Sep 5, 2017

My brain started working again, it's indeed a solution and I don't really need to do it programmatically. Thank you very much

@knezi
Copy link

knezi commented Sep 11, 2017

Hi to all,
this option for switching layouts is not applicable to my use case. I use the following two layouts:

setxkbmap cz-prog,cz-moje -variant ,ucw -option grp:caps_switch

setxkbmap us,cz-moje -variant ,ucw -option grp:caps_switch

between which I toggle with a small bash script. I can't use Alt+Shift to toggle between them, because it uses capslock as a switch between the variants. The question is if there is any way to switch between these two without the need of restarting sway?

@ddevault
Copy link
Member

No, that's not presently possible.

@knezi
Copy link

knezi commented Sep 11, 2017 via email

@ddevault
Copy link
Member

No. It should be possible when wlroots is complete.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

6 participants