Received: from mx0.gmx.net (mx0.gmx.net [213.165.64.100]) by h1439878.stratoserver.net (8.14.2/8.14.2/Debian-2build1) with SMTP id p29IPKhh003222 for ; Wed, 9 Mar 2011 19:25:22 +0100 Received: (qmail 18329 invoked by alias); 9 Mar 2011 18:25:15 -0000 Delivered-To: GMX delivery to rainer.schoepf@gmx.net Received: (qmail invoked by alias); 09 Mar 2011 18:25:15 -0000 Received: from relay2.uni-heidelberg.de (EHLO relay2.uni-heidelberg.de) [129.206.210.211] by mx0.gmx.net (mx064) with SMTP; 09 Mar 2011 19:25:15 +0100 Received: from listserv.uni-heidelberg.de (listserv.uni-heidelberg.de [129.206.100.94]) by relay2.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id p29INBF4009360 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Wed, 9 Mar 2011 19:23:11 +0100 Received: from listserv.uni-heidelberg.de (localhost.localdomain [127.0.0.1]) by listserv.uni-heidelberg.de (8.13.1/8.13.1) with ESMTP id p29IHvPc005446; Wed, 9 Mar 2011 19:23:02 +0100 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 16.0) with spool id 1272440 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Wed, 9 Mar 2011 19:23:02 +0100 Received: from relay2.uni-heidelberg.de (relay2.uni-heidelberg.de [129.206.210.211]) by listserv.uni-heidelberg.de (8.13.1/8.13.1) with ESMTP id p29IN23t002227 for ; Wed, 9 Mar 2011 19:23:02 +0100 Received: from moutng.kundenserver.de (moutng.kundenserver.de [212.227.17.8]) by relay2.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id p29IMw0V009198 for ; Wed, 9 Mar 2011 19:23:01 +0100 Received: from morse.mittelbach-online.de (p54A83BF6.dip.t-dialin.net [84.168.59.246]) by mrelayeu.kundenserver.de (node=mreu2) with ESMTP (Nemesis) id 0MSmwb-1PVZem21MT-00ReFw; Wed, 09 Mar 2011 19:22:57 +0100 Received: by morse.mittelbach-online.de (Postfix, from userid 501) id 5C58574EEE; Wed, 9 Mar 2011 19:22:54 +0100 (CET) MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit References: <4D738DB1.3020807@gmx.de> <19831.22704.372331.894399@morse.mittelbach-online.de> <56ED2B8C-74D6-4163-A98C-52B8CA052724@frycomm.com> X-Mailer: VM 7.19 under Emacs 21.3.1 X-Provags-ID: V02:K0:3BfH2ZRTcDaKRGjlGCxQiNR4oEwueskwcfZz6nFZKvd EV+l1NnKFCJsXfrq9a2VMkmWH6CCK4/uJXeD1Pqz1OVUsyCVWj m7qm3gOL6hrnU0Sz8gGUl5mKCvSgX4wSsaqQ90v8Zhwk5vz0xz 5jIJhtb2qOLzPCP4bwCpufBOVFqHweNJCTiAPDqFWzkLuVwMWs zGh9RIvTiKum6e//76Mew== X-Spam-Whitelist-Provider: Message-ID: <19831.50558.187028.513243@morse.mittelbach-online.de> Date: Wed, 9 Mar 2011 19:22:54 +0100 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Frank Mittelbach Subject: Re: format? To: LATEX-L@listserv.uni-heidelberg.de In-Reply-To: Precedence: list List-Help: , List-Unsubscribe: List-Subscribe: List-Owner: List-Archive: X-GMX-Antispam: 0 (Mail was not recognized as spam); Detail=5D7Q89H36p77e5KAPs1l6v/Sb97LojnDtMgfETrECMLUO9erHzOJe7j3G660N4yBY6XHH YPYtmQj6mbYUTZ3LnaFANLWrKE7/wIDhnv+VrW0hxOapLRUwuY9oBqo5h+Dh9B42XlFTMTKlXDju GaV8Q==V1; X-Resent-By: Forwarder X-Resent-For: rainer.schoepf@gmx.net X-Resent-To: rainer@rainer-schoepf.de Status: R X-Status: X-Keywords: X-UID: 6659 Philipp > > > > Would it be possible to build the format in such a way that the packages > > in question are built into it, but not activated unless such line(s) were > > present in the document? > > I thought about this issue, but how should this be done on the technical > level? Once you have defined a TeX macro, there is no way to "deactivate" > it. I had the hope that it would be possible to require either > \NeedsTeXFormat{LaTeX2x} or \usepackage{expl3...}, but I don't think there > is a simple way to do this. there are possibilities of various sophistication. A simple approach for just expl3 would be something like \ActivateExplCode \DeactivateExplCode where the latter would simply hook into some core functions like the arg expansion mechanism, e.g., replacing \exp_args:No and a few others with a suitable error message when called. And \ActivateExplCode would \cs_set_eq:NN the orig definitions back. All you would need to do would be to select the right kind of code pieces to make this work. > > Would there need to be an ``\activatepackage'' command? Or is there some > > better command which should be used in LaTeX3? I've complained in the > > past of LaTeX2e document pre-ambles being meaningless line-after-line of > > \usepackage{foo} and would really like to see a nicer interface here --- > > would this be a good opportunity to introduce it? > > This is not possible given the package system of LaTeX 2e: packages are > just source code files that are read byte by byte, similar to C header > files. After a package has been loaded, all macros defined by the package > are defined and stay so forever. A more sound approach is to build a > monolithic system and to get rid of TeX programming as far as > possible that is what ConTeXt Mk IV does. for abitrary packages that would be a little trickier but not impossibe either. Even if code stays forever, per package there are usually only one or two definitions that you would need to highjack and rename to make such a scheme fly. I don't agree with the statement that this needs a monolithic system. Yes such a system makes a lot of things easier, but then there are also advantages in the openess of the LaTeX world as far as third-party packages are concerned. cheers frank