From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/77747 Path: news.gmane.org!not-for-mail From: Aditya Mahajan Newsgroups: gmane.comp.tex.context Subject: Re: Using MPgraphics as externalfigures? Date: Fri, 3 Aug 2012 17:28:47 -0400 (EDT) Message-ID: References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; Format="flowed" Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1344029234 27544 80.91.229.3 (3 Aug 2012 21:27:14 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 3 Aug 2012 21:27:14 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Fri Aug 03 23:27:10 2012 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SxPOm-0008BS-9k for gctc-ntg-context-518@m.gmane.org; Fri, 03 Aug 2012 23:27:08 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 3EB20101FC; Fri, 3 Aug 2012 23:27:07 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Yhd2nDboT1FR; Fri, 3 Aug 2012 23:27:05 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id A52BD101E5; Fri, 3 Aug 2012 23:27:05 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id C5810101E5 for ; Fri, 3 Aug 2012 23:27:03 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id V9AdP29HItZt for ; Fri, 3 Aug 2012 23:27:02 +0200 (CEST) Original-Received: from filter2-til.mf.surf.net (filter2-til.mf.surf.net [194.171.167.218]) by balder.ntg.nl (Postfix) with ESMTP id 75550101E0 for ; Fri, 3 Aug 2012 23:27:02 +0200 (CEST) Original-Received: from hackers.mr.itd.umich.edu (smtp.mail.umich.edu [141.211.14.81]) by filter2-til.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id q73LR0nP005436 for ; Fri, 3 Aug 2012 23:27:01 +0200 Original-Received: FROM Decentralized.ECE.McGill.CA (Decentralized.ECE.McGill.CA [132.206.69.142]) By hackers.mr.itd.umich.edu ID 501C4223.19DF7.23018 ; Authuser adityam; 3 Aug 2012 17:26:59 EDT In-Reply-To: User-Agent: Alpine 2.02 (LNX 1266 2009-07-14) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=141.211.14.81; country=US; region=MI; city=Ann Arbor; postalcode=48109; latitude=42.2923; longitude=-83.7145; metrocode=505; areacode=734; http://maps.google.com/maps?q=42.2923,-83.7145&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0THGlr00E - 40eb6f47914c - 20120803 (trained as not-spam) X-Scanned-By: CanIt (www . roaringpenguin . com) on 194.171.167.218 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.14 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 Original-Sender: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:77747 Archived-At: On Thu, 2 Aug 2012, Mari Voipio wrote: > Hi All, > > I'm being a bit clueless about the MPgraphics again... > > I've got a pile of instructional graphics that will be used and reused > in a project. My first try is/was an unwieldy buffer construction, but > I'm sure there's a better way than > > \placefigure[here] > [fig: 5 loop departed setup] > {The start position for a 5-loop braid with departed loops} > {\framed{\getbuffer[setup 5-loop basic]}} > > > Come to think of it, is there another way of framing the incoming > graphic? I don't want to include the frames in the MPcode as I may not > always want them, but that \framed{\getbuffer} construction is > downright ugly. (Untested code, but this should work) \startbuffer[figure 1] draw fullcircle scaled 1cm; \stopbuffer \startbuffer[frame] draw (bbox currentpicture) withcolor blue; \stopbuffer \processMPbuffer[figure 1, frame] Basically, you can concatinate various buffers in \processMPbuffer. Aditya ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________