Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

I have a Windows XP computer with two languages installed: English and Hebrew. (This question would be relevant to anyone who uses XP with multiple languages, regardless of which languages.)

I can use Alt-Shift to change between English and Hebrew. Sometimes I need to write in English, and sometimes in Hebrew. But when I use a certain program, Wing IDE, I always want to write in English. But sometimes I don't notice it's set to Hebrew, and I start typing, and it comes out as gibberish, and then I press Ctrl-Z only to remember that Wing wouldn't accept that shortcut key in Hebrew mode. Really annoying.

Is there any way to automatically switch language to English when I focus on my IDE?

share|improve this question
    
I do not have Windows at hand, but AFAIR it remembers keyboard layouts either per window or per application. Either way, if you never switch to Hebrew in the IDE, then it will never be the case that you have to switch from Hebrew. –  chronos Aug 26 '10 at 21:53
add comment

3 Answers

Autohotkey! Seriously. It's free and it includes a recorder. Start recording, follow the steps you need to switch languages and fire up Wing IDE, stop recording, save the recorded script with a meaningful name like StartWingIDE, create a shortcut to the script and use that to start Wing IDE instead of its regular shortcut. You can even change the new shortcut's icon so that it looks like the Wing IDE shortcut. Tada!

share|improve this answer
    
The problem is not when starting Wing IDE. It's when switching to it. I start Wing IDE maybe once a day; I switch to it hundreds of time a day. –  Ram Rachum Aug 21 '10 at 15:29
    
@cool-RR: Ah, okay. –  boot13 Aug 21 '10 at 15:45
    
You can still use AHK with a script to switch to Hebrew when you make the Wing window active. AutoIt would also work - not as a macro, but as a script that is always running and checking which window is open and acting accordingly –  SamGoody Nov 25 '12 at 9:08
add comment

I don't know of an automatic way of solving this problem, but there is a way to simplify keyboard layout changes.

If you go to Control Panel / Regional and Language Options / Languages / Details / Key Settings, you can define hotkeys for language changes.

I don't suppose that your version of Wing IDE has an option to run a script when gaining the focus?
If it does, then a programmatic solution would be easy enough.

I see that all versions of Wing IDE have "Customizable user interface", while the Professional version has "Extend IDE with Python scripting" which sounds promising. It would help to know which version you have, but not having Wing IDE installed, I can't search any further.

share|improve this answer
add comment

Ahi, there is no simple answer here as if you'd like to make this change happen instantly when focusing on your IDE you'll have to create some wrapper that will macro it.

In XFCE I can set the keybd-language settings per-application so if you can use linux environment you should try it.

there is somewhat of a solution for your situation. I use hebrew too, and I noticed that when I set the default language to be english, the keyboard resets to english automatically when i switch between applications. minimizing occurrences of such pain and anger:)

shalom.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.