manual vs automatic saved sessions

CiAsA S'Nuey Boark ciasaboark at
Wed Dec 17 05:22:21 GMT 2003

Hash: SHA1

On Tuesday December 16 2003 07:43 am, Tim Middleton wrote:
> Can i use dcop to save a "logout" sessoin" at any time?
> [...]
> I *finally* discovered a post to the debian-kde mailing list (though i
> don't use debian myself) where someone shared the great secret... you have
> to actually select and apply the "Restore manually saved sessions" option
> on the control pannel before the option appears. Is this not rather
> obscure?

Well, not really.  The idea behind it is that if you are gonna automagically 
save the session on exit and restore it at every login, there is 
(theoretically) no need for a save session button/icon/selection anywhere.  
The only time you should need it is when your gonna save a session manually 
and have that session restored at every login.  I guess the k-menu was deemed 
the correct place to put it.

> The original query in the thread I found that revealed this occult
> knowledge actually was looking for a similar solution to myself. But it
> doens't seem to be in KDE, strangely...

<hint>I'm sure the documentation team would love a hand ;)</hint>

> My problem is that my box for various reasons is often unstable and
> crashes. The session restoring code in KDE is wonderful... except that when
> my box crashes the sessions are not saved, and i end up booting up and
> restoring whatever session was saved days or weeks ago. This renders the
> feature next to useless (since i rarely ever shut down except for crashes).
> [...]
> What would be ideal is to have KDE save sessions automatically at an
> interval. This functionality doesn't seem to be in KDE... so I was
> wondering if there is a dcop call that i could cron to do this...

Definitely, this is where theoretical meets reality

> I have discovered using kdcop the ksmserver.ksmserver.saveCurrentSession()
> and .saveCurrentSessionAs(QString) ... and .sessionList(). Using the latter
> at the comand line I see:
>   $ dcop ksmserver ksmserver sessionList
>   default
>   saved at previous logout
>   saved by user
> Can i assume saveCurrentSession() saves to "saved by user"? Is there any
> problem with my executing any time I want:
> $ dcop ksmserver ksmserver saveCurrentSessionAs "saved at previous logout"

Well, after five minutes of messing around I couldn't get KDE to restore any 
session saved via dcop.  This is trying both restoring manually saved 
sessions, and restoring logout sessions.  Tried both saveCurrentSession as 
well as saveCurrentSessionAs for default "saved at previous logout" and 
"saved by user".  All combinations failed.  (this is on a fairly recent cvs 

Slightly OT, but it would also be nice if KDE was able to handle multiple 
saved sessions, and prompt on startup for what session the user would like to 
restore.  I think I've read some request along this line a while back.
- -- 
Jonathan Nelson []
Version: GnuPG v1.2.3 (GNU/Linux)

This message is from the kde mailing list.
Account management:
More info:

More information about the kde mailing list