From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/61959 Path: news.gmane.org!not-for-mail From: Philipp Gesang Newsgroups: gmane.comp.tex.context Subject: \definenamespace and module setup (was: Info about creating modules for beginners.) Date: Sat, 25 Sep 2010 17:07:33 +0200 Message-ID: <20100925150733.GA12482@aides> References: <4C9B81EB.7080404@gyza.cz> <4C9BB968.8020100@wxs.nl> <6FE1A002-DDBA-4AFB-9C2D-0C27A776A212@st.estfiles.de> <1F8CEAD2-29F9-45FC-845F-77550E1849CB@gmail.com> <78A01E48-A117-4758-A125-BB608B184B84@gmail.com> <8F2347FB-8CE7-446E-B304-3D7F2FE11106@st.estfiles.de> <4C9BC855.2000509@gyza.cz> <1E3C1BB4-CBEC-4D72-BF4C-C7A3F43CBBB8@gmail.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1511029473==" X-Trace: dough.gmane.org 1285427236 29681 80.91.229.12 (25 Sep 2010 15:07:16 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sat, 25 Sep 2010 15:07:16 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Sat Sep 25 17:07:15 2010 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 1OzWLJ-0003iX-Sa for gctc-ntg-context-518@m.gmane.org; Sat, 25 Sep 2010 17:07:13 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id E1698CA711; Sat, 25 Sep 2010 17:07:12 +0200 (CEST) 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 C+u7-82HPxbg; Sat, 25 Sep 2010 17:07:10 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id E0597CA703; Sat, 25 Sep 2010 17:07:09 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 63928CA703 for ; Sat, 25 Sep 2010 17:07:08 +0200 (CEST) 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 C0NKnDH7grO6 for ; Sat, 25 Sep 2010 17:07:05 +0200 (CEST) Original-Received: from filter2-nij.mf.surf.net (filter2-nij.mf.surf.net [195.169.124.153]) by balder.ntg.nl (Postfix) with ESMTP id 35C19CA6FF for ; Sat, 25 Sep 2010 17:07:05 +0200 (CEST) Original-Received: from relay2.uni-heidelberg.de (relay2.uni-heidelberg.de [129.206.210.211]) by filter2-nij.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id o8PEvql8002121 for ; Sat, 25 Sep 2010 16:57:53 +0200 Original-Received: from ix.urz.uni-heidelberg.de (cyrus-portal.urz.uni-heidelberg.de [129.206.100.176]) by relay2.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id o8PF9Z34005531 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Sat, 25 Sep 2010 17:09:35 +0200 Original-Received: from extmail.urz.uni-heidelberg.de (extmail.urz.uni-heidelberg.de [129.206.100.140]) by ix.urz.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id o8PF73dr032381 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Sat, 25 Sep 2010 17:07:03 +0200 Original-Received: from localhost (mnhm-4d01221a.pool.mediaWays.net [77.1.34.26]) (authenticated bits=0) by extmail.urz.uni-heidelberg.de (8.13.4/8.13.1) with ESMTP id o8PF6t3E011553 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES128-SHA bits=128 verify=NO) for ; Sat, 25 Sep 2010 17:06:56 +0200 In-Reply-To: <1E3C1BB4-CBEC-4D72-BF4C-C7A3F43CBBB8@gmail.com> X-Operating-System: Linux aides 2.6.35-ARCH X-Polite-Request: "Please try to be nice, don't send html mail." User-Agent: Mutt/1.5.20 (2009-06-14) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=129.206.210.211; country=DE; region=01; city=Heidelberg; latitude=49.4167; longitude=8.7000; http://maps.google.com/maps?q=49.4167,8.7000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0aDb2VQiD - 6da93b04b2be - 20100925 X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.153 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:61959 Archived-At: --===============1511029473== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="17pEHd4RhPHOinZp" Content-Disposition: inline --17pEHd4RhPHOinZp Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On 2010-09-23 <23:43:15>, Wolfgang Schuster wrote: > These are namespaces but you don't need these constructs > anymore in mkiv because there is now a \definenamespace command > which takes care of this. Hi Wolfgang, following your fancybreak module I put together dummy module. =C2=B7=C2=B78<=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7= =C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2= =B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7= =C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2= =B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7= =C2=B7 \startmodule[test] \unprotect \startinterface all \setinterfacevariable {TEST} {TEST} \stopinterface \definenamespace[testns] [ type=3Dmodule, name=3DTEST, command=3Dyes, setup=3Dlist, ] \unexpanded\def\typetest{% \TESTparameter{teststyle} This is a test.% } \defineTEST[\v!TEST] \setupTEST[ teststyle=3D\sc ] \protect \endinput =C2=B7=C2=B78<=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7= =C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2= =B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7= =C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2= =B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7=C2=B7= =C2=B7 When called like: \usemodule[test] \starttext \typetest \stoptext it works as expected. Could you please explain what these other parameters do: style=3Dyes, parent=3Dfb Also, what other values would the parameter =E2=80=98setup=E2=80=99 accept besides =E2=80=98list=E2=80=99? > BTW: The two letter namespaces are reserved for Hams and me but > you=E2=80=99re free to use longer ones (we should collect them on a page > at the wiki). What information should go into this list? In my dummy, the namespace =E2=80=98testns=E2=80=99 declares the \defineXX and \setupXX comm= ands, where XX=3Dname and name=3DTEST. Thus if I am not mistaken, namespace clashes might occur both a) among the \????=E2=80=A6, and b) among the \setup=E2=80=A6|\define=E2=80=A6 commands. A table on the wiki will need at least three columns: +-----------+------------+---------------------+ | Namespace | Setup | Reserved for module | +=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D+=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D+=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D+ | fb | fancybreak | Fancy Break | +-----------+------------+---------------------+ | =E2=80=A6 | =E2=80=A6 | =E2=80=A6 | Is this OK so far? Anything critical I missed? Philipp --=20 () ascii ribbon campaign - against html e-mail /\ www.asciiribbon.org - against proprietary attachments --17pEHd4RhPHOinZp Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iEYEARECAAYFAkyeEDUACgkQ02lYlJYWs9KGpACePo2xsQiig6/0HvG1bzcjG43n ApMAoJrtlmR2kLT6LC4ZTd/s8rZcrMpX =l0sB -----END PGP SIGNATURE----- --17pEHd4RhPHOinZp-- --===============1511029473== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ --===============1511029473==--