From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?iso-8859-1?Q?Vincent_Bela=EFche?= Newsgroups: gmane.emacs.devel Subject: Re: SES local variables to define printers Date: Thu, 30 May 2013 09:24:30 +0200 Message-ID: <80d2s9nd5d.fsf@gmail.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1369898730 9800 80.91.229.3 (30 May 2013 07:25:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 30 May 2013 07:25:30 +0000 (UTC) To: Stefan Monnier , emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu May 30 09:25:29 2013 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 1UhxEm-0005Ad-GV for ged-emacs-devel@m.gmane.org; Thu, 30 May 2013 09:25:28 +0200 Original-Received: from localhost ([::1]:49260 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UhxEm-00086S-3r for ged-emacs-devel@m.gmane.org; Thu, 30 May 2013 03:25:28 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:52024) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UhxEf-00086H-IU for emacs-devel@gnu.org; Thu, 30 May 2013 03:25:26 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UhxEa-0008AH-Nv for emacs-devel@gnu.org; Thu, 30 May 2013 03:25:21 -0400 Original-Received: from smtp04.smtpout.orange.fr ([80.12.242.126]:40136 helo=smtp.smtpout.orange.fr) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UhxEa-00089y-HD for emacs-devel@gnu.org; Thu, 30 May 2013 03:25:16 -0400 Original-Received: from CHOUNEK ([92.135.232.123]) by mwinf5d51 with ME id i7RE1l0052gQEcC037REn9; Thu, 30 May 2013 09:25:15 +0200 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-Received-From: 80.12.242.126 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:159911 Archived-At: Replying to myself... > From: vincent.b.1@hotmail.fr > To: monnier@iro.umontreal.ca; emacs-devel@gnu.org > Subject: Re: SES local variables to define printers > Date: Thu, 30 May 2013 07:50:08 +0200 > [...] > > Ok you means _after_ the ses-cell declaration, just before those general > declarations (taken from examples.ses): > > (ses-column-widths [15 15]) > (ses-column-printers [nil nil]) > (ses-default-printer "%.7g") > (ses-header-row 0) > [...] One more question: when you define a symbol as local (e.g. with make-local-variable), does it mean only the value slot of the symbol is made local, or do you have also the function slot made local. The hack which I have done also consisted in allowing to use the value slot to define a function. That was just because file local variables affect only the value slot, not the function slot. But on the other hand, I am not even sure that EMACS lisp allow to create file local functions. What I could do if there is no such a thing as file local function is to set the symbol value slot to some specific symbol, say :ses-printer, and use the symbol name as a key to a hash map containing all local printers. Vincent.