From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/34064 Path: news.gmane.org!not-for-mail From: nicola Newsgroups: gmane.comp.tex.context Subject: Re: Relationship among mptopdf, mpost and latex Date: Sat, 31 Mar 2007 19:33:40 +0200 Organization: --- Message-ID: References: <6faad9f00703281759s3f56c6e6q76479d67a8f62518@mail.gmail.com> <460B79B1.6070204@elvenkind.com> <460BD166.8040304@wxs.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1175362462 31467 80.91.229.12 (31 Mar 2007 17:34:22 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sat, 31 Mar 2007 17:34:22 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Sat Mar 31 19:34:20 2007 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 lo.gmane.org with esmtp (Exim 4.50) id 1HXhT1-0006mj-4P for gctc-ntg-context-518@m.gmane.org; Sat, 31 Mar 2007 19:34:19 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id A5DF820163; Sat, 31 Mar 2007 19:34:18 +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 12264-04; Sat, 31 Mar 2007 19:34:13 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 19A6A2014E; Sat, 31 Mar 2007 19:34:13 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 716592014E for ; Sat, 31 Mar 2007 19:34:11 +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 12428-03-2 for ; Sat, 31 Mar 2007 19:34:04 +0200 (CEST) Original-Received: from ciao.gmane.org (main.gmane.org [80.91.229.2]) by ronja.ntg.nl (Postfix) with ESMTP id D7088200DC for ; Sat, 31 Mar 2007 19:34:04 +0200 (CEST) Original-Received: from list by ciao.gmane.org with local (Exim 4.43) id 1HXhSe-0005gB-6K for ntg-context@ntg.nl; Sat, 31 Mar 2007 19:33:56 +0200 Original-Received: from host40-5.pool8175.interbusiness.it ([81.75.5.40]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 31 Mar 2007 19:33:56 +0200 Original-Received: from vitacolo by host40-5.pool8175.interbusiness.it with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 31 Mar 2007 19:33:56 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 69 Original-X-Complaints-To: usenet@sea.gmane.org X-Gmane-NNTP-Posting-Host: host40-5.pool8175.interbusiness.it User-Agent: MT-NewsWatcher/3.5.2 (PPC Mac OS X) X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 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:34064 Archived-At: In article <460BD166.8040304@wxs.nl>, Hans Hagen wrote: > Taco Hoekwater wrote: > > Mojca Miklavec wrote: > > > >> I remember that Hans claimed that texmfstart (or texexec) could be > >> convinced to process LaTeX documents (and there is some mention of > >> latex command in core indeed), but I never managed to make it work. > >> > > > > LaTeX has worked only in the very beginning, when I was still > > using latex somewhat regularly, and afaik I was the only tester > > of that code (Btw, that means texexec dates back to at least the > > year 2000). > > > i can probably extend texexec easily to do the multipass latex thing > (just as i support plain tex) but it has a low priority (useless to make > something that no one will use or only one or two users) > > About mptopdf: something is definately wrong there, and it really > > should be fixed. It is totally pointless when mptopdf processes > > only context-based files properly, since these are the only ones > > that do not _need_ mptopdf in the first place. > > > > > i remember fixing something because a latex user asked for it but usually > don't test that (samep for supp-pdf), so if i get solutions i can put them in > (i need to rewrite the thing anyway) I have browsed mptopdf.pl code and I have discovered that I can process my original example with mptopdf --rawmp --metafun example.mp (en passant, it would be nice if 'mptopdf --help' showed the available options). The script recognizes when LaTeX is being used (lines 78--84), but unless --rawmp is given, it processes the file with texexec (which, as far as I have understood, does not currently work correctly with LaTeX, even if it probably should). It has turned out that the combination mptopdf/latex seems quite an unusual one: apparently, a ConTeXt user does not need to care about LaTeX stuff (of course); on the other hand, a LaTeX user might want to include the powerful MetaFun macros in raw MetaPost files (that was my case), without using ConTeXt. The latter can be accomplished as shown above, which implies mpost --tex=latex --progname=mpost --mem=metafun So, why not change mptopdf.pl so that it uses the command above when the latex switch is present and texexec only when there is no LaTeX related stuff? That is, change lines 86-100 to read: if ($Latex) { # Use mpost + metafun macros $mpbin = "mpost --tex=latex --progname=mpost --mem=metafun" ; } else { $mpbin = "texexec --mptex $PassOn" ; } The rationale here is that, probably, the more complicated processing by texexec is not relevant to the LaTeX user. My other question was: is page 5, ?1 in metafun-p.pdf obsolete? As I have already pointed out, 'input mp-tool; input mp-spec;' at the beginning of my original example results in no errors, but the output has a blank figure. Or is this a question for the metapost mailing list? Nicola