From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: emacs save/restore state? Date: Wed, 16 May 2012 10:38:38 -0400 Message-ID: References: <87vckza6z9.fsf@nzebook.haselwarter.org> <24E6E440EE274805816259B172420E37@us.oracle.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1337179141 9980 80.91.229.3 (16 May 2012 14:39:01 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 16 May 2012 14:39:01 +0000 (UTC) Cc: emacs-devel@gnu.org, 'Philipp Haselwarter' To: "Drew Adams" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Wed May 16 16:38:59 2012 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SUfNS-0000Jw-JA for ged-emacs-devel@m.gmane.org; Wed, 16 May 2012 16:38:58 +0200 Original-Received: from localhost ([::1]:57559 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SUfNR-0000x4-JE for ged-emacs-devel@m.gmane.org; Wed, 16 May 2012 10:38:57 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:47977) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SUfNG-0000wu-MG for emacs-devel@gnu.org; Wed, 16 May 2012 10:38:56 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SUfNB-0006Xy-U0 for emacs-devel@gnu.org; Wed, 16 May 2012 10:38:46 -0400 Original-Received: from ironport-out.teksavvy.com ([206.248.143.162]:51635) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SUfNB-0006XW-Pg for emacs-devel@gnu.org; Wed, 16 May 2012 10:38:41 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: ApYIACxOgk9FpZcD/2dsb2JhbABDuCMDgQyBCIIJAQEEAVYjBQsLNBIUGA0kLoduBbYyi2GEeQSkRYFdgwM X-IronPort-AV: E=Sophos;i="4.75,391,1330923600"; d="scan'208";a="180521142" Original-Received: from 69-165-151-3.dsl.teksavvy.com (HELO pastel.home) ([69.165.151.3]) by ironport2-out.teksavvy.com with ESMTP/TLS/ADH-AES256-SHA; 16 May 2012 10:38:38 -0400 Original-Received: by pastel.home (Postfix, from userid 20848) id 31A3359339; Wed, 16 May 2012 10:38:38 -0400 (EDT) In-Reply-To: (Drew Adams's message of "Wed, 16 May 2012 06:24:10 -0700") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.1.50 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 206.248.143.162 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:150521 Archived-At: > True. This wishlist occurs to me, to keep in mind when looking for > a solution: > 1. Factoring out some code commonality would be good (modulo other wishes). > 2. Users should be able to save histories without necessarily saving > all the other desktop stuff. > 3. Users should be able to save other desktop stuff without > necessarily saving histories. > 4. Users can save multiple desktops, which should be able to have > different saved histories. IOW, a given history variable, e.g., > `file-name-history', could have a different saved value in > different desktops. Agreed. I think the way forward is to restructure the code so desktop.el can use savehist-mode (e.g. so it can tell it where/when to save the history). There's a similar issue with saveplace.el (again, with slightly different semantic but no good reason why saveplace.el can't provide the needed flexibility for desktop.el to use it and let the user choose between the usual desktop.el semantics or the usual saveplace.el semantics). Stefan