From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/16239 Path: main.gmane.org!not-for-mail From: Matthias Weber Newsgroups: gmane.comp.tex.context Subject: Re: Metapost and TeX Date: Mon, 23 Aug 2004 22:02:50 -0500 Sender: ntg-context-bounces@ntg.nl Message-ID: <156E4279-F57A-11D8-94A4-000A959AFACC@indiana.edu> References: <77347076e58b.76e58b773470@tampabay.rr.com> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 (Apple Message framework v618) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1093316549 9558 80.91.224.253 (24 Aug 2004 03:02:29 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 24 Aug 2004 03:02:29 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Tue Aug 24 05:02:22 2004 Return-path: Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BzRZm-0008Gb-00 for ; Tue, 24 Aug 2004 05:02:22 +0200 Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 3224312778; Tue, 24 Aug 2004 05:02:22 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (ronja.vet.uu.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 04465-05; Tue, 24 Aug 2004 05:02:20 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 185021276C; Tue, 24 Aug 2004 05:02:20 +0200 (CEST) Original-Received: from localhost (localhost.localdomain [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id B34431276C for ; Tue, 24 Aug 2004 05:02:17 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (ronja.vet.uu.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 05154-01-2 for ; Tue, 24 Aug 2004 05:02:16 +0200 (CEST) Original-Received: from rockridge.uits.indiana.edu (unknown [129.79.1.74]) by ronja.ntg.nl (Postfix) with ESMTP id B664E126F8 for ; Tue, 24 Aug 2004 05:02:16 +0200 (CEST) Original-Received: from mail-relay.iu.edu (stjoseph.uits.indiana.edu [129.79.1.78]) by rockridge.uits.indiana.edu (8.12.10/8.12.10/IUPO) with ESMTP id i7O32C1W014908; Mon, 23 Aug 2004 22:02:13 -0500 (EST) Original-Received: from [10.0.1.2] (dial-123-71.dial.indiana.edu [156.56.123.71]) (authenticated bits=0) by mail-relay.iu.edu (8.12.10/8.12.10/IUPO) with ESMTP id i7O329rr016884 (version=TLSv1/SSLv3 cipher=RC4-SHA bits=128 verify=NO); Mon, 23 Aug 2004 22:02:12 -0500 (EST) In-Reply-To: <77347076e58b.76e58b773470@tampabay.rr.com> Original-To: skhilji@tampabay.rr.com, mailing list for ConTeXt users X-Mailer: Apple Mail (2.618) X-Virus-Scanned: by amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.5 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: by amavisd-new at ntg.nl Xref: main.gmane.org gmane.comp.tex.context:16239 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:16239 This is not exactly an answer to your question, but it might solve your problem. You can use overlays with any figure, see cont-eni.pdf page 150ff. The mechanism is not so much the tex-engine TeX but one of the many little add-ons that come with ConText and exploit features of PDF. In particular, you can use your PDFs directly in ConText. I found this easier than to teach my picture producing applications to use the right fonts in the right way at the right place. Matthias On Aug 23, 2004, at 9:48 PM, skhilji@tampabay.rr.com wrote: > I don't have any experience in metapost. I would appreciate if > someone would please answer this question without me having to do thru > tutorials and metapost source code. > > I was wondering how does metapost talk to TeX? Quicky glancing > through the metafun book, I found out that you can super-impose text > typeset by TeX on top of a diagram. I imagine you could do the same > with mathematical equations too. > > So how does metapost interact with TeX? Let me guess: > > 1) Metapost could first write down to a file the text that it wan't > TeX to typeset. It could then run TeX on the file. TeX produces a > DVI file and metapost reads it back. It can then superimpose it on > top of a picture. > > 2) Metapost could also be including within itself a simplified > version of TeX. But that would be reinventing the wheel. > > So how does it happen in reality? > > The reason that I am asking is that I am interested in producing some > diagrams using the libHARU PDF library (a C++ library to produce PDF > files). Beautiful Text support, however, is missing from the library. > I was wondering if I could hack it up so that I could somehow use TeX > for the text part and C++ calls for the graphics part. > > > _______________________________________________ > ntg-context mailing list > ntg-context@ntg.nl > http://www.ntg.nl/mailman/listinfo/ntg-context > >