Received: from mail.proteosys.com ([213.139.130.197]) by nummer-3.proteosys with Microsoft SMTPSVC(6.0.3790.3959); Fri, 21 Aug 2009 09:46:40 +0200 Received: by mail.proteosys.com (8.14.3/8.14.3) with ESMTP id n7L7keOI025044 for ; Fri, 21 Aug 2009 09:46:40 +0200 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 n7L7h6HZ020874 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 21 Aug 2009 09:43:06 +0200 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 n7KM1YeK008874; Fri, 21 Aug 2009 09:43:05 +0200 Received: by LISTSERV.UNI-HEIDELBERG.DE (LISTSERV-TCP/IP release 15.5) with spool id 286746 for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Fri, 21 Aug 2009 09:43:05 +0200 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 n7L7h5Lu022782 for ; Fri, 21 Aug 2009 09:43:05 +0200 Received: from ueamailgate02.uea.ac.uk (ueamailgate02.uea.ac.uk [139.222.131.185]) by relay2.uni-heidelberg.de (8.13.8/8.13.8) with ESMTP id n7L7gnBY020728 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO) for ; Fri, 21 Aug 2009 09:42:53 +0200 Received: from ueams02.uea.ac.uk (ueams02.uea.ac.uk [139.222.131.131]) by ueamailgate02.uea.ac.uk (8.13.1/8.13.1) with ESMTP id n7L7gnAG026540 for ; Fri, 21 Aug 2009 08:42:49 +0100 Received: from [139.222.114.191] by ueams02.uea.ac.uk with esmtp (Exim 4.69) (envelope-from ) id 1MeOlo-0005Vs-Nq for LATEX-L@LISTSERV.UNI-HEIDELBERG.DE; Fri, 21 Aug 2009 08:42:44 +0100 User-Agent: Thunderbird 2.0.0.22 (Windows/20090605) MIME-Version: 1.0 References: <874332F9-007B-4945-87D5-48B28BBC11CC@gmail.com> <4A8E304C.4050208@morningstar2.co.uk> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Canit-CHI2: 0.00 X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN, outgoing) X-CanItPRO-Stream: UEA:outgoing (inherits from UEA:default,base:default) X-Canit-Stats-ID: 28672460 - 1b5e19df8873 X-Scanned-By: MIMEDefang 2.65 on 213.139.130.197 X-Scanned-By: CanIt (www . roaringpenguin . com) on 139.222.131.185 Message-ID: <4A8E4FF9.1080100@morningstar2.co.uk> Date: Fri, 21 Aug 2009 08:42:49 +0100 Reply-To: Mailing list for the LaTeX3 project Sender: Mailing list for the LaTeX3 project From: Joseph Wright Subject: Re: template customising To: LATEX-L@LISTSERV.UNI-HEIDELBERG.DE In-Reply-To: Precedence: list List-Help: , List-Unsubscribe: List-Subscribe: List-Owner: List-Archive: X-ProteoSys-SPAM-Score: -6.599 () BAYES_00,RCVD_IN_DNSWL_MED Return-Path: owner-latex-l@LISTSERV.UNI-HEIDELBERG.DE X-OriginalArrivalTime: 21 Aug 2009 07:46:41.0025 (UTC) FILETIME=[85669710:01CA2233] Status: R X-Status: X-Keywords: X-UID: 5967 Will Robertson wrote: >> Of course, this >> leaves open the question of how much variation each template leaves >> open. I can see your argument for creating instances with only minor >> adjustments from existing ones ("All I want to do is change length a to >> length b, leaving everything else alone."). My feeling is that the idea >> is that document classes should be much clearer on the settings they >> use, so the cost of copying a template and altering only a few lines is >> worth it in clarity of what is going on. > > ...sometimes there are simply lots of settings to adjust! :) > Something like a single section heading template could feasibly have > > - number size & font > - title size & font > - title paragraph shape > - number indent > - number-to-title skip > - pre-material (penalty & skip & possible rule) > - post-material (ditto) > > I agree that most of these *should* be reset when any of them are, but > sometimes you just want to change the pre/post-skip or whatever, and I > don't think it's convenient to have to find the definition of the > instance and copy/paste the whole thing. No, I'd agree. There is something of a balancing act to do here, at least without something like \EditInstance (I'd suggest \EditInstanceFromTemplate based on my suggestion that \DeclareInstanceFromTemplate is more accurate than just \DeclareInstance). I imagine that we will end up providing one or more very general templates with some restricted ones to solve at least parts of the issue. So you might imagine \DeclareTemplate { sectioning } { std-complete-customisation } ... \DeclareRestrictedTemplate { sectioning } { std-font-variable } { std-complete-customisation } \DeclareRestrictedTemplate { sectioning } { std-spacing-variable } { std-complete-customisation } where we put all of the possible changes in the first one then cut down on the possibles in the second one. There is also the point that the template values will probably have a default. So if you only want to change one thing from what is "out of the box" then you only need \DeclareInstance { type } { name } { template } { one-changed-key = value } The problem only comes if you want to change a few keys in an instance that already sets several things in the template. >> The danger of allowing >> something like \EditInstance is that you can easily get back to ad hoc >> changes here and there with no clear separation of design and document >> code. > > Provided that the \EditInstance goes together with the other > customisations for the document, I don't really see how this blurs the > line between the two. Isn't it just a more convenient way to completely > redeclare the instance without knowing the original settings? > > But maybe you're right, and I'm trying to add a feature to solve a > problem that is better solved in another way (e.g., by declaring more > and more restricted templates and redefining the instances from scratch > as you suggest). I'm not saying no. Frank will I'm sure have more insight into this, but I can see that it would be convenient to quickly alter a few settings from an existing file. That is, after all, how a lot of LaTeX2e classes are constructed. On the other hand, I suppose you can argue that the useful thing about forcing each class to be self-contained is that you are less likely to run into the problem that LaTeX2e has, that lots of classes make assumptions about the base design that now cannot be changed. -- Joseph Wright