LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Java applications ignore keyboard layout change (https://www.linuxquestions.org/questions/linux-general-1/java-applications-ignore-keyboard-layout-change-695300/)

bitpicker 01-06-2009 05:27 AM

Java applications ignore keyboard layout change
 
I am using a Gentoo system with XFce and Sun Java JRE 1.6. My keyboard uses a German layout, but as I am learning Russian I have added the ability to switch to Russian (genuine, not phonetic). This works well, only Java applications (jVLT for learning vocabulary and JBidWatcher, which I just tested to prove the problem is java-related) ignore the setting.

I can copy and paste Russian into jVLT, but cannot type it there directly. Instead, the symbols which turn up are the standard symbols defined by the German keyboard layout.

I suppose there's a way to set the keyboard layout for Java specifically, or something like that. Can anyone point me in the right direction?

Thanks in advance.

Robin

ErV 01-06-2009 10:44 PM

Quote:

Originally Posted by bitpicker (Post 3398663)
I am using a Gentoo system with XFce and Sun Java JRE 1.6.

"jre-1.6" doesn't tell anything. Make sure that your java version is something like jre-1.6.0_11(as on my machine), and not just 1.6.0. If it is simply 1.6.0, then you should probably update your java runtime environment to the latest currently available.

Quote:

Originally Posted by bitpicker (Post 3398663)
My keyboard uses a German layout, but as I am learning Russian I have added the ability to switch to Russian (genuine, not phonetic). This works well, only Java applications (jVLT for learning vocabulary and JBidWatcher, which I just tested to prove the problem is java-related) ignore the setting.

I can copy and paste Russian into jVLT, but cannot type it there directly. Instead, the symbols which turn up are the standard symbols defined by the German keyboard layout.

I suppose there's a way to set the keyboard layout for Java specifically, or something like that. Can anyone point me in the right direction?

Thanks in advance.

Robin

I had similar problem in the past. In my case it was caused by wrong locale: Java accepted russian input only if LANG was set to ru_RU.UTF-8 but didn't accept russian input if LANG was set to ru_RU.UTF8 (notice missing dash between "F" and "8"). I don't remember, how I figured it out. Check your locale ("LANG" variable). If it ends with .UTF8 (which is probably the case), make it .UTF-8 and try again.

bitpicker 01-07-2009 12:21 AM

The JRE is 1.6.0.11.

My current locale settings are:

Code:

locale
LANG=de_DE.UTF-8@euro.UTF-8
LC_CTYPE="de_DE.UTF-8@euro.UTF-8"
LC_NUMERIC="de_DE.UTF-8@euro.UTF-8"
LC_TIME="de_DE.UTF-8@euro.UTF-8"
LC_COLLATE="de_DE.UTF-8@euro.UTF-8"
LC_MONETARY="de_DE.UTF-8@euro.UTF-8"
LC_MESSAGES="de_DE.UTF-8@euro.UTF-8"
LC_PAPER="de_DE.UTF-8@euro.UTF-8"
LC_NAME="de_DE.UTF-8@euro.UTF-8"
LC_ADDRESS="de_DE.UTF-8@euro.UTF-8"
LC_TELEPHONE="de_DE.UTF-8@euro.UTF-8"
LC_MEASUREMENT="de_DE.UTF-8@euro.UTF-8"
LC_IDENTIFICATION="de_DE.UTF-8@euro.UTF-8"
LC_ALL=de_DE.UTF-8@euro.UTF-8

So they all have the dash.

Robin

ErV 01-07-2009 06:35 AM

Quote:

Originally Posted by bitpicker (Post 3399540)

So they all have the dash.

Robin

I think this locale is not fully supported by java runtime envioronment.
Check if this locale is supported by jre (list of supported locales is somewhere on the internet - google for it).
Anyway, I tried de_DE.UTF-8@euro.UTF-8 on my machine, it doesn't work (russian letters discarded when I type). However, de_DE.UTF-8 works fine (can type russian letters without problems).

dickgregory 01-07-2009 07:24 AM

I can't help you with your question, but something about your post impressed me. I assume that your native language is German. You are learning Russian, and your post used excellent English. I've tried several times to learn a second language (Spanish) and even though it is spoken all around me, I've never been able to even become conversant.

I wish more native English speakers would learn to use the quality of English that you demonstrate in your posts.

Q. What do you call a person that speaks 2 languages?
A. Bilingual.
Q. What do you call a person that speaks 3 languages?
A. Trilingual.
Q. What do you call a person that speaks 1 language?
A. An American.

bitpicker 01-07-2009 08:08 AM

Thanks, Dick. :)

You're right, my native language is German. But I studied English literature and linguistics at university and I spend most of my online time on English sites and most of my quite extensive reading is in English, too. When I went to school English was more or less compulsory from age ten, nowadays students at school here in Germany begin learning English as early as the first year at school.

I dare not hope to reach a similar level of fluency in any further language I might take up, though. At almost forty the brain isn't such a language sponge anymore. ;)

Robin


All times are GMT -5. The time now is 04:49 AM.