From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.help Subject: Re: Save and load window states Date: Wed, 21 Dec 2011 16:29:34 +0100 Message-ID: <4EF1FB5E.7090008@gmx.at> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1324481397 32115 80.91.229.12 (21 Dec 2011 15:29:57 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 21 Dec 2011 15:29:57 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: phaebz@gmail.com Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed Dec 21 16:29:53 2011 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1RdO76-0005jH-5a for geh-help-gnu-emacs@m.gmane.org; Wed, 21 Dec 2011 16:29:52 +0100 Original-Received: from localhost ([::1]:32971 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RdO74-00078U-Pt for geh-help-gnu-emacs@m.gmane.org; Wed, 21 Dec 2011 10:29:50 -0500 Original-Received: from eggs.gnu.org ([140.186.70.92]:45868) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RdO6y-00078O-9D for help-gnu-emacs@gnu.org; Wed, 21 Dec 2011 10:29:48 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RdO6s-00039R-7z for help-gnu-emacs@gnu.org; Wed, 21 Dec 2011 10:29:44 -0500 Original-Received: from mailout-de.gmx.net ([213.165.64.22]:53830) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1RdO6r-00039D-R0 for help-gnu-emacs@gnu.org; Wed, 21 Dec 2011 10:29:38 -0500 Original-Received: (qmail invoked by alias); 21 Dec 2011 15:29:34 -0000 Original-Received: from 62-47-56-217.adsl.highway.telekom.at (EHLO [62.47.56.217]) [62.47.56.217] by mail.gmx.net (mp056) with SMTP; 21 Dec 2011 16:29:34 +0100 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1+ZOS8FVemZ6fMSVpNURMy5Gkwurd7C16VPKCYTH6 The8zM+kuV8lNF User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) Original-References: 4ef0b02d.0d0a0e0a.60bc.080d@mx.google.com X-Y-GMX-Trusted: 0 X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 213.165.64.22 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:83234 Archived-At: > Saving works this way. The file has the same contents shown in the > *Messages* buffer when doing a manual `window-state-get'. On loading, I > get either "Invalid read syntax #" This is a bug. Please report it as Drew suggested. > or "End of file during parsing". This is probably due to the fact that you called `my-load-frame' twice in a row and you were already at the end of the buffer in the second call so there was nothing more to read. > I am thinking that this has something to do with how emacs reads and > evaluates objects. Partly, yes. > Can someone give me a hint on how to make it work? Please comment out the two code lines (unless (window-parameter window 'clone-of) ;; Make a clone-of parameter. (setq list (cons (cons 'clone-of window) list))) in the function `window--state-get-1' and recompile window.el (possibly twice - I'm somewhat confused by Stefan's backquote syntax here). These lines are currently for internal use only, their absence should not harm you. If you still see problems, please tell me. Thanks, martin