Dear all,

It's been a while since I first asked this question. I would like to try again.

I am attempting to set the '_NET_WM_STATE_SKIP_TASKBAR' and '_NET_WM_STATE_SKIP_PAGER' states to a window.

For this I used:

window.set_wm_state(Display().intern_atom('_NET_WM_STATE_SKIP_TASKBAR'))

where "window" is a resource object created from a winID.

When I run this however it raises a TypeError:

  File "/home/benjamin/Programming/Qontrol/src/xwindow.py", line 39, in set_wm_state_skip_taskbar
    self._window.set_wm_state(Display().intern_atom('_NET_WM_STATE_SKIP_TASKBAR'))
  File "/usr/lib/pymodules/python2.7/Xlib/xobject/drawable.py", line 749, in set_wm_state
    self._set_struct_prop(atom, atom, icccm.WMState, hints, keys, onerror)
  File "/usr/lib/pymodules/python2.7/Xlib/xobject/drawable.py", line 785, in _set_struct_prop
    keys.update(hints)

Could you please advise me?
Thanks.
Benjamin



On 2 June 2011 13:13, Benjamin Trias <jesuisbenjamin@gmail.com> wrote:
Hi everyone,

I don't want to bombard you with questions, but in spite of having
looked at the documentation, i could not find out how to use
window.set_wm_state()
inspect.getargspec() and inspect.getsource() tell me i should pass a
hint={} variable.
>From the documentation
(http://standards.freedesktop.org/wm-spec/wm-spec-1.4.html#id2551694)
i reckon i need to pass '_NET_WM_STATE_ADD' but i'm not sure of
expected syntax.
I would like to pass the '_NET_WM_STATE_SKIP_TASKBAR' hint to my
application's window.
Could you please give me some guidance?

Thanks.
Benjamin