stumpwm-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[STUMP] Re: How to handle (xlib:get-property (window-xwin w) :_NET_WM_PI


From: Sharad Pratap
Subject: [STUMP] Re: How to handle (xlib:get-property (window-xwin w) :_NET_WM_PID)) value
Date: Sat, 1 Aug 2009 12:32:59 +0530


Hi Michael,

> As far as I understood your original goal, you do not need to make tag
> corresponding to the command executed.

No I wanted to cover or differentiate among (exec "mozilla -P prof1") (exec "mozilla -P prof2")
and in fact it return as :class Seamonky not Mozilla
Only thing left I am not able to handle (xlib:get-property (window-xwin w) :_NET_WM_PID) what value it
return, how to handle it.
when I am trying to use `message' on it it throw error

  (#pid) fell through ETYPECASE _expression_, Wanted (string simple-string)
once it is done I can assign map cmd to pid, and later when window appear, I will
extract pid and tag it with corresponding cmd,
In case as some window not return _NET_WM_PID I will have to fall back to match
:Class, window-role, :window-instance.

this cmd tags will be kept with group where window created, and moved, and
when group changed it will raise all these tags.

Regards,
-sharad

On Sat, Aug 1, 2009 at 11:57 AM, Michael Raskin <address@hidden> wrote:
Sharad Pratap wrote:
> I am capturing `cmd' text  all space remove for  tag and  recognizing
> its  X client by its xwin:_NET_WM_PID
> property. and associating the X client with tag that I have prepared.)

As far as I understood your original goal, you do not need to make tag
corresponding to the command executed. You probably want to make a
global variable to keep the "name" of the current group. This name will
be set on group switch (simultaneously with pull+push-tag) and this name
will be used to tag all new windows.

At the same time you can use the new-window hook to tag windows based on
their window-class or window-instance or window-role. Usually
window-class is similar to the command used to launch the program which
created the window.



--
Regard
        (`
        _) h a r a d


reply via email to

[Prev in Thread] Current Thread [Next in Thread]