VectorLinux

The nuts and bolts => X-Rated => Topic started by: caitlyn on January 07, 2016, 07:44:26 pm

Title: Language switching within an X session [RESOLVED]
Post by: caitlyn on January 07, 2016, 07:44:26 pm
Hi, everyone,

While my question is about Hebrew, I imagine the issue would be the same with any non-Latin character set so I'm hoping someone who is using two character sets (i.e.: Latin & Cyrillic) will know the answers.

I've finally put VL64 7.1 on my system with the Hebrew/English keyboard.  If I change the language when I login to Hebrew everything works fine in Hebrew and the keyboard can be switched back to English which also works.  However, if I login with a U.S. English locale, even if I change the keyboard setting to Israeli I can't seem to type in Hebrew at all.  This doesn't happen in other distros:  i.e.: language switching within an X session works fine in Debian or CentOS or whatever else I throw at this machine.   

I have added this to my .bashrc
setxkbmap -option grp:switch,grp:alt_shift_toggle,grp_led:scroll us,il

I also have tried setting keyboard switching in the XFCE keyboard settings app.

Has anyone got keyboard and character set switching working in XFCE without logging out?
Title: Re: Language switching within an X session
Post by: macondo on January 08, 2016, 05:03:47 pm
https://wiki.archlinux.org/index.php/Keyboard_configuration_in_Xorg

This is a shot in the dark...I don't use xfce  :(
Play with it, try putting this in your .xinitrc:

Code: [Select]
setxkbmap -model pc104 -layout il,us -option grp:alt_shift_toggle

I don't know if your computer is pc104 or pc105.
See if alt-shift toggles the 2 languages, find out if you can toggle with the Caps Key :) (much faster)
Good luck!
Title: Re: Language switching within an X session
Post by: roarde on January 08, 2016, 05:45:01 pm
Part the first:
Open a run dialog.
env LANG=he_IL.UTF8 abiword

That may give you some progress, but I doubt it's the whole solution. Part the second would be to load a proper font, of which I am ignorant.

Spanish will work just by changing the keyboard because the characters needed are already in most left-to-right Latin UTF8 sets. But for Hebrew you need right-to-left and an entirely different set of characters, right?
Title: Re: Language switching within an X session
Post by: caitlyn on January 09, 2016, 03:11:33 pm
I clearly didn't explain the problem well.  If I login with a Hebrew/Israeli locale everything works.  Right to left is fine, the fonts are already in VL, keyboard switching works just fine.  If I login with a US English locale it just wouldn't allow me to enter anything in Hebrew.  I'd get nothing.

I did figure out the problem, BTW, and it's the fact that the default locale in VL 7.1 is en_US rather than en_US.UTF8.  If I change it to en_US.UTF8 everything works.
Title: Re: Language switching within an X session [RESOLVED]
Post by: macondo on January 10, 2016, 08:37:28 am
Glad to hear, congrats!