From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: ludo@gnu.org (Ludovic =?iso-8859-1?Q?Court=E8s?=) Newsgroups: gmane.lisp.guile.user Subject: Re: procedure-source availability Date: Thu, 04 Oct 2012 18:16:32 +0200 Message-ID: <87r4pecivz.fsf@gnu.org> References: <506910C0.7060108@netris.org> <87y5jp9de5.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1349401881 24441 80.91.229.3 (5 Oct 2012 01:51:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 5 Oct 2012 01:51:21 +0000 (UTC) Cc: guile-user@gnu.org To: Panicz Maciej Godek Original-X-From: guile-user-bounces+guile-user=m.gmane.org@gnu.org Fri Oct 05 03:51:24 2012 Return-path: Envelope-to: guile-user@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 1TJx4P-0006Y7-4U for guile-user@m.gmane.org; Fri, 05 Oct 2012 03:51:17 +0200 Original-Received: from localhost ([::1]:43160 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TJo6m-00065h-8u for guile-user@m.gmane.org; Thu, 04 Oct 2012 12:17:08 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:54367) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TJo6N-00052J-9y for guile-user@gnu.org; Thu, 04 Oct 2012 12:16:47 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TJo6F-0004GZ-Dh for guile-user@gnu.org; Thu, 04 Oct 2012 12:16:43 -0400 Original-Received: from xanadu.aquilenet.fr ([88.191.123.111]:60108) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TJo6F-0004GD-7b for guile-user@gnu.org; Thu, 04 Oct 2012 12:16:35 -0400 Original-Received: from localhost (localhost [127.0.0.1]) by xanadu.aquilenet.fr (Postfix) with ESMTP id E9F507794; Thu, 4 Oct 2012 18:16:32 +0200 (CEST) Original-Received: from xanadu.aquilenet.fr ([127.0.0.1]) by localhost (xanadu.aquilenet.fr [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id GTNyjsoZAIG6; Thu, 4 Oct 2012 18:16:32 +0200 (CEST) Original-Received: from pluto (unknown [193.50.110.215]) by xanadu.aquilenet.fr (Postfix) with ESMTPSA id A962BDAE; Thu, 4 Oct 2012 18:16:32 +0200 (CEST) X-URL: http://www.fdn.fr/~lcourtes/ X-Revolutionary-Date: 13 =?iso-8859-1?Q?Vend=E9miaire?= an 221 de la =?iso-8859-1?Q?R=E9volution?= X-PGP-Key-ID: 0xEA52ECF4 X-PGP-Key: http://www.fdn.fr/~lcourtes/ludovic.asc X-PGP-Fingerprint: 83C4 F8E5 10A3 3B4C 5BEA D15D 77DD 95E2 EA52 ECF4 X-OS: x86_64-unknown-linux-gnu In-Reply-To: (Panicz Maciej Godek's message of "Tue, 2 Oct 2012 21:29:34 +0200") User-Agent: Gnus/5.130005 (Ma Gnus v0.5) Emacs/24.2 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 88.191.123.111 X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane.org@gnu.org Original-Sender: guile-user-bounces+guile-user=m.gmane.org@gnu.org Xref: news.gmane.org gmane.lisp.guile.user:9609 Archived-At: Hi, Panicz Maciej Godek skribis: > Well, the idea for now is that the associated .spec file containing > the state of GUI is loaded on startup, and the state of the > interpreter is dumped to that file on exit (or at GUI's request). > Viewing the file will obviously be an option (for the curious user), > but any modifications would probably be overwritten eventually (unless > the file is write-protected). > > This approach allows avoiding the design of any specific file format > to store information about the GUI -- everything is just scheme. The > only requirement is that all used object (images etc.) can be dumped > to scheme expressions, evaluation of which would re-create them. (This > isn't yet fully implemented, but I'm on a good way) This sounds like an interesting approach. Instead of storing actual code that recreates the GUI, how about storing high-level declarations that describe that GUI? For instance, Ratpoison & co. store declarations like this: (frame :number 0 :x 0 :y 0 :width 1320 :height 1200 :screenw 1920 :screenh 2000 :window 12582930 :last-access 6 :dedicated 0) They could instead store actual code (say, a procedure that creates a window of the right size, using the X11 API, etc.). However, the advantage of declarative code is that it=E2=80=99s easy to maintain backward-compatibility (compared to regular API churn), and it also allows for portability between implementations (for instance, Ratpoison vs. StumpWM vs. RPX.) And, it=E2=80=99s also easily serialized. Hope I=E2=80=99m not too off-topic. ;-) Ludo=E2=80=99.