From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/30325 Path: news.gmane.org!not-for-mail From: "Mojca Miklavec" Newsgroups: gmane.comp.tex.context Subject: Re: figure directory is sort of searched Date: Wed, 16 Aug 2006 19:02:34 +0200 Message-ID: <6faad9f00608161002w28c0419bue1e40d88f87fb0c4@mail.gmail.com> References: <44E183D7.1060001@elvenkind.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1155747893 10598 80.91.229.2 (16 Aug 2006 17:04:53 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 16 Aug 2006 17:04:53 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Wed Aug 16 19:04:52 2006 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by ciao.gmane.org with esmtp (Exim 4.43) id 1GDOoq-000144-D3 for gctc-ntg-context-518@m.gmane.org; Wed, 16 Aug 2006 19:04:40 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 902DD1FE60; Wed, 16 Aug 2006 19:04:39 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 09366-02; Wed, 16 Aug 2006 19:04:32 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 752681FE55; Wed, 16 Aug 2006 19:04:32 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 7E9DC1FE2B for ; Wed, 16 Aug 2006 19:04:28 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 07600-07 for ; Wed, 16 Aug 2006 19:04:21 +0200 (CEST) Original-Received: from wx-out-0506.google.com (wx-out-0506.google.com [66.249.82.224]) by ronja.ntg.nl (Postfix) with SMTP id ABA6F1FE5C for ; Wed, 16 Aug 2006 19:02:35 +0200 (CEST) Original-Received: by wx-out-0506.google.com with SMTP id s12so166252wxc for ; Wed, 16 Aug 2006 10:02:34 -0700 (PDT) Original-Received: by 10.48.220.15 with SMTP id s15mr967662nfg; Wed, 16 Aug 2006 10:02:34 -0700 (PDT) Original-Received: by 10.78.175.15 with HTTP; Wed, 16 Aug 2006 10:02:34 -0700 (PDT) Original-To: "mailing list for ConTeXt users" In-Reply-To: <44E183D7.1060001@elvenkind.com> Content-Disposition: inline X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.7 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 X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:30325 Archived-At: On 8/15/06, Taco Hoekwater wrote: > > Hi, > > Sanjoy Mahajan wrote: > > I still can't figure this problem one out, from a few months ago, and it > > happens with a recent ConTeXt (2006.08.08 21:51). The figure searching > > code gets confused if a file of the same basename (but in a different > > directory) has already been loaded. Here is a minimal min.tex to show > > what I mean: > > I remember I ran into that as well (more than a year ago) and I ended > up renaming my figures to figure1-1.pdf etc. It actually turned out > to be easier for me, because that way I could use the figure filename > as the reference. While reading Taco's response something else came to my mind: here's what I did in one of the presentations: \startsetups award:gold \useexternalfigure[medal][medal_gold][height=7.5cm] \stopsetups \startsetups award:silver \useexternalfigure[medal][medal_silver][height=7.5cm] \stopsetups \startsetups award:bronze \useexternalfigure[medal][medal_bronze][height=7.5cm] \stopsetups After that I just issued \setups{award:gold} at the top of "product file" for gold medallists while using the same page layout for all the medallists (with a simple \externalfigure[medal] which was good for any medallist). I guess that you could also do something like \startsetups chapter:1 \useexternalfigure[fig-1][1/fig-1.pdf] \useexternalfigure[fig-2][1/fig-2.pdf] \stopsetups \startsetups chapter:2 \useexternalfigure[fig-1][2/fig-1.pdf] ... \stopsetups \starttext \setups{chapter:1} \externalfigure[fig-1] \externalfigure[fig-2] \setups{chapter:2} \externalfigure[fig-1] \stoptext Just out of curiosity I tried the following: \startsetups chapter:1 \dorecurse{10}{\useexternalfigure[fig-\recurselevel][1/fig-\recurselevel.pdf]} \stopsetups \startsetups chapter:2 \dorecurse{10}{\useexternalfigure[fig-\recurselevel][2/fig-\recurselevel.pdf]} \stopsetups But you should ask someone else where to "expand" stuff to make it work. Mojca