Make devilspie2 handle windows closing too

52 views
Skip to first unread message

Devilspie2

unread,
Jan 26, 2013, 7:23:20 PM1/26/13
to devil...@googlegroups.com
Hey users of devilspie2!

Every now and then I get support questions or suggestions that suggests
that devilspie2 need to be able to handle windows closing in addition
to the windows opening as it does currently.

What do you as users think about this? How should I handle this?

The libwnck that devilspie2 is based on can handle these situations
just fine - There are signals for both windows closing and windows
opening (which is what devilspie2 is handling right now).

I have got a suggestion that indeed seems very reasonable - as it is now
files are xxxxxxx.lua - If one wants to handle a window closing - add a
suffix to the filename -

xxxxxx.closed.lua

and all lua code in there will only be called when a window is closing.

This should make it possible to do something like saving window
geometry when a window is closed, and then restoring the same geometry
when that window is opened again. (I haven't tried it if it will work
the way I want it though - it _might_ be the case that you cannot get
the window geometry on window closing, but I haven't tried yet so I
don't know anything for sure - I will make a branch in the git
repository for experimentation).

(Check out http://developer.gnome.org/libwnck/stable/WnckScreen.html -
underneath "signals" to get a list on the signals that I can handle in
the wnck library.)

Any thoughts, ideas, suggestions?

best regards and thank you for using devilspie2
/Andreas Rönnquist
devil...@gusnan.se
--
_
( ) ascii ribbon campaign - against html e-mail
X www.asciiribbon.org - against proprietary attachments
/ \

Laurent

unread,
Jan 27, 2013, 4:30:53 PM1/27/13
to devil...@googlegroups.com
Hi Andreas

I'd prefer a user managed context in which we could store any kind of data (events, geometries, window's type, etc.), so that we could be smarter when placing windows.
I'm not fond of naming conventions to manage behaviour, because IMHO it's often too restrictive eventualy.

Laurent.
Reply all
Reply to author
Forward
0 new messages