Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

Hide/Show a Program /w Macro~Python

Name: Shira 2009-05-02 15:33

Ok, so I'm learning Python as my first language. I know the basic syntax and everything by this point, so I've moved onto some more advanced things. The problem is for the program I'm writing now, I want the main application window to Hide/Show by a hot key. How would I go about doing this in Python?

I'm trying to make this App cross platform, as I plan on using it on my Windows and my Linux boxes. (It's cool if I need to use C/C++ or whatever else to accomplish this, since Python should allow me to use other languages in the script.)

I've toyed with the idea of making a Daemon to run constantly looking for the key combo, but that seems largely pointless and near impossible to do with Python.

ALSO: nb4 SICP

Name: Shira 2009-05-02 16:53

>>4
wxGlade, but I'm not sure I see why it matters.

Name: Shira 2009-05-02 16:54

>>6
>>7
ok that was weird...

Name: Shira 2009-05-02 17:38

>>9
All I'm getting from this is to use C instead of Python, and run the Python script inside it. I would rather just use Python as the entirety if possible. all the WM hooks are written for one OS or the other, nothing cross platform. Is there anyway I can make the program monitor the keyboard for the hotkey, with out having to limit it to hooking on only one OS ?

Name: Anonymous 2009-05-02 19:49

>>12
Perhaps you should re-read my original post. I'm asking how to do global hotkey monitoring in Python. To be quite honest, I'm not interested in hearing your philosophy about why hotkey monitoring is a Bad Thing(tm), I'm interested only in results.

Name: Shira 2009-05-02 19:57

>>12
Further more, the program I'm trying to build is similar to the app launcher Launchy if you have ever heard of it and or used it. I want it to be able to come up by a hotkey and allow the user to interact, and then hide its self when the same hotkey is pressed.
Would it be easier to think of it as a Terminal emulator, with a Hide Show feature, because more or less that's what it will be in the end. I'm aware that I'm reinventing the wheel, but I would like to build one in Python.

Name: Shira 2009-05-02 20:02

>>12
If it helps your view of hotkeys being evil for taking control from the user, the end result will include a settings menu to allow the user to choose the hotkey for the program.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List