From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/67332 Path: news.gmane.org!not-for-mail From: Ulrike Fischer Newsgroups: gmane.comp.tex.context Subject: Re: search path for require(...) Date: Thu, 24 Mar 2011 12:41:42 +0100 Message-ID: <1utkce0a0kkh9$.dlg@nililand.de> References: <55a1sy0sjbc.dlg@nililand.de> <20110324101400.GC3626@orcus> <20110324105047.GE3626@orcus> Reply-To: news3@nililand.de, mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-13" Content-Transfer-Encoding: quoted-printable X-Trace: dough.gmane.org 1300966940 3654 80.91.229.12 (24 Mar 2011 11:42:20 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 24 Mar 2011 11:42:20 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Thu Mar 24 12:42:16 2011 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Q2ivg-00052W-5d for gctc-ntg-context-518@m.gmane.org; Thu, 24 Mar 2011 12:42:16 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 479B4CAB4A; Thu, 24 Mar 2011 12:42:01 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id zsyPOzBEPuU3; Thu, 24 Mar 2011 12:41:58 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 1F1ACCAB42; Thu, 24 Mar 2011 12:41:58 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 4C326CAB42 for ; Thu, 24 Mar 2011 12:41:57 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id bnKpOV7AcD91 for ; Thu, 24 Mar 2011 12:41:55 +0100 (CET) Original-Received: from filter5-til.mf.surf.net (filter5-til.mf.surf.net [194.171.167.221]) by balder.ntg.nl (Postfix) with ESMTP id F30BBCAB31 for ; Thu, 24 Mar 2011 12:41:54 +0100 (CET) Original-Received: from lo.gmane.org (lo.gmane.org [80.91.229.12]) by filter5-til.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id p2OBg6N2014561 for ; Thu, 24 Mar 2011 12:42:08 +0100 Original-Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Q2ivV-0004w7-Ii for ntg-context@ntg.nl; Thu, 24 Mar 2011 12:42:05 +0100 Original-Received: from pd954bb53.dip.t-dialin.net ([217.84.187.83]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 24 Mar 2011 12:42:05 +0100 Original-Received: from news3 by pd954bb53.dip.t-dialin.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Thu, 24 Mar 2011 12:42:05 +0100 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 38 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: pd954bb53.dip.t-dialin.net User-Agent: 40tude_Dialog/2.0.15.41de X-Bayes-Prob: 0.9999 (Score 4.7, tokens from: @@RPTN) X-CanIt-Geo: ip=80.91.229.12; country=NO; latitude=62.0000; longitude=10.0000; http://maps.google.com/maps?q=62.0000,10.0000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0xEmXG6h3 - d1d3016aeab0 - 20110324 X-Scanned-By: CanIt (www . roaringpenguin . com) on 194.171.167.221 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:67332 Archived-At: Am Thu, 24 Mar 2011 11:50:47 +0100 schrieb Philipp Gesang: >>> (You=FFre going to have to declare the table =B4chessfss=A1 globally >>> for this to work.) >> = >> The chessfss.lua has a "return Table" at the end which declares the >> table chessfss. = >> = >> To quote from http://lua-users.org/wiki/LuaModuleFunctionCritiqued: >> = >> "The problems above can be avoided by not using the module function >> but instead defining modules in the following simple way: [*1][*2] = > = > Of course, that=FFs the Lua way. I can=FFt guess what you=FFre up to > but if it=FFs going to eventually become a module, the =B4chessfss=A1 > table should not pollute the global namespace. There are > canonical locations (check luat-ini.lua) where the functions and > data should go: > = > http://www.ntg.nl/pipermail/ntg-context/2010/054982.html > = > So you might be better off dropping =B4require=A1 altogether and just > conclude your module with a line like: > = > thirddata =3D thirddata or { } > thirddata.chessfss =3D chessfss > = > instead of returning a table, then loading it with =B4loadluafile=A1. = I'm not writing a module but virtual fonts, and they can be used with context and latex. So whatever I will be doing should not be context specific. But I will test if I can keep the chessfss-table local, and if not put it in thirddata if it exists. -- = Ulrike Fischer = ___________________________________________________________________________= ________ If your question is of interest to others as well, please add an entry to t= he Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-cont= ext webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________= ________