Session Management
GNOME provides tools to allow your application to run smoothly from session to session. Users can log out with running applications and have those applications fully restored when they log back in. To provide this functionality, your application must connect to the session manager and save its state when the user logs out.
Note that this section is outdated as GnomeClient and Libgnomeui are deprecated. Newly written code should use EggSMClient instead. Work is currently underway to integrate EggSMClient directly into GTK+. API and ABI stability guarantees ensures that GnomeClient will continue to be functional and supported throughout the GNOME 2 lifecycle.
GNOME provides a simple API for session management in the GNOME User Interface Library. See the section GnomeClient of the GNOME UI Library Reference Manual for more information on working with the GNOME session manager.