472,374 Members | 1,377 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 472,374 software developers and data experts.

Detect current virtual desktop

Hello Pythonists,

I'd like to write for myself a tiny program that counts time spent on each
virtual desktop (in GNOME). In order to do that, I need my program to
detect the current virtual desktop. I've googled for it for about one hour
and couldn't find any solution. The closest thing I found is set of
tutorials: http://www.pygtk.org/articles.html Unfortunately, none of them
answers my questions:

How to detect current virtual desktop in GNOME? How to detect a virtual
desktop change?

--
http://automatthias.wordpress.com
Aug 21 '06 #1
2 2276
Maciej Bliziński wrote:
How to detect current virtual desktop in GNOME? How to detect a virtual
desktop change?
Take a look at http://wallpapoz.sourceforge.net/
Harald
Aug 21 '06 #2
On Mon, 21 Aug 2006 12:52:59 +0200, Harald Karner wrote:
Maciej Bliziński wrote:
>How to detect current virtual desktop in GNOME? How to detect a virtual
desktop change?
Take a look at http://wallpapoz.sourceforge.net/
Harald, many thanks.

By the way, I have found the line of code I was interested in. It is
stunningly simple, just calls the xprop command:

os.popen('xprop -root _NET_CURRENT_DESKTOP').read()

--
http://automatthias.wordpress.com

Aug 21 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

14
by: rogerclive | last post by:
Perhaps, there is no bigger sleazy company in the entire Maple Republic ( Canada ) than Matrox Graphics Inc. I paid $100+ through my nose circa 1999 for Matrox Millenium II and Mystique. It...
15
by: Jim Hubbard | last post by:
Is it possible to emulate a monitor (create a virtual monitor) using vb.net? Any code snippets or pointers to helpful articles would be very much appreciated.
9
by: Tim | last post by:
Hi Guys, I was wondering if there is a way to detect from with a C# app if it is being started in a remote session? i.e. someone has connected via remote desktop or terminal services... ...
2
by: John Brock | last post by:
At work we are using a virtual desktop manager called AltDesk (http://www.astonshell.com/), and it is causing a weird and extremely annoying problem with the VB.NET application I am developing. ...
9
by: desktop | last post by:
On this page: http://www.eptacom.net/pubblicazioni/pub_eng/mdisp.html Shape specify the virtual function: virtual double Intersect( const Shape& s) = 0; then the derived class Circle...
7
by: desktop | last post by:
This page: http://www.eptacom.net/pubblicazioni/pub_eng/mdisp.html start with the line: "Virtual functions allow polymorphism on a single argument". What does that exactly mean? I guess it...
2
by: macracan | last post by:
It has been discussed before, but I still can't find a solution and I have a need. So here goes: The problem: I'm writing a something to handle messages from XWindows. The idea is to have...
0
by: =?Utf-8?B?am1hZ2FyYW0=?= | last post by:
My program needs to do X when someone 'starts using' their Windows user account, and it should do Y when they 'stop using' their Windows user account. By 'starts using' I mean they log on, unlock...
0
by: Naresh1 | last post by:
What is WebLogic Admin Training? WebLogic Admin Training is a specialized program designed to equip individuals with the skills and knowledge required to effectively administer and manage Oracle...
0
hi
by: WisdomUfot | last post by:
It's an interesting question you've got about how Gmail hides the HTTP referrer when a link in an email is clicked. While I don't have the specific technical details, Gmail likely implements measures...
0
by: Carina712 | last post by:
Setting background colors for Excel documents can help to improve the visual appeal of the document and make it easier to read and understand. Background colors can be used to highlight important...
0
BLUEPANDA
by: BLUEPANDA | last post by:
At BluePanda Dev, we're passionate about building high-quality software and sharing our knowledge with the community. That's why we've created a SaaS starter kit that's not only easy to use but also...
2
by: Ricardo de Mila | last post by:
Dear people, good afternoon... I have a form in msAccess with lots of controls and a specific routine must be triggered if the mouse_down event happens in any control. Than I need to discover what...
1
by: Johno34 | last post by:
I have this click event on my form. It speaks to a Datasheet Subform Private Sub Command260_Click() Dim r As DAO.Recordset Set r = Form_frmABCD.Form.RecordsetClone r.MoveFirst Do If...
1
by: ezappsrUS | last post by:
Hi, I wonder if someone knows where I am going wrong below. I have a continuous form and two labels where only one would be visible depending on the checkbox being checked or not. Below is the...
0
DizelArs
by: DizelArs | last post by:
Hi all) Faced with a problem, element.click() event doesn't work in Safari browser. Tried various tricks like emulating touch event through a function: let clickEvent = new Event('click', {...
0
by: F22F35 | last post by:
I am a newbie to Access (most programming for that matter). I need help in creating an Access database that keeps the history of each user in a database. For example, a user might have lesson 1 sent...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.