From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/32632 Path: news.gmane.org!not-for-mail From: Aditya Mahajan Newsgroups: gmane.comp.tex.context Subject: Re: placing a tikz/pgf figure Date: Tue, 9 Jan 2007 17:51:28 -0500 (EST) Message-ID: References: <20070109164240.58526.qmail@web51807.mail.yahoo.com> <45A3DBD8.70803@boede.nl> <45A3EC67.2030502@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 1168383125 3067 80.91.229.12 (9 Jan 2007 22:52:05 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 9 Jan 2007 22:52:05 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Tue Jan 09 23:52:03 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 1H4Poy-0000ob-Do for gctc-ntg-context-518@m.gmane.org; Tue, 09 Jan 2007 23:51:56 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 221C41FFC5; Tue, 9 Jan 2007 23:48:20 +0100 (CET) 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 08589-05-15; Tue, 9 Jan 2007 23:48:13 +0100 (CET) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 9B5B31FF87; Tue, 9 Jan 2007 23:48:13 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 0713D1FF87 for ; Tue, 9 Jan 2007 23:48:11 +0100 (CET) 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 08589-05-14 for ; Tue, 9 Jan 2007 23:48:05 +0100 (CET) Original-Received: from hackers.mr.itd.umich.edu (smtp.mail.umich.edu [141.211.14.81]) by ronja.ntg.nl (Postfix) with ESMTP id 4F38D1FF5F for ; Tue, 9 Jan 2007 23:48:05 +0100 (CET) Original-Received: FROM aditya.engin.umich.edu (udhcp-wlan86.public.engin.umich.edu [141.213.120.96]) BY hackers.mr.itd.umich.edu ID 45A41C71.60CAC.6375 ; 9 Jan 2007 17:51:29 -0500 Original-To: mailing list for ConTeXt users In-Reply-To: <45A3EC67.2030502@wxs.nl> 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:32632 Archived-At: On Tue, 9 Jan 2007, M.J. Kallen wrote: > Hi all, > > I'm trying to determine how to best insert a figure/graph created > using the tikz/pgf module (I'm using v1.10). The attached sample > file compares the result of just using \placefigure and \placefigure > with \startcombination[1*1]. In the first case, the result is not > centered (which should be default in ConTeXt, if I'm correct) but > flushed left. Only if I place the figure inside a \startcombination > by using \input, do I get the desired result. If I use > \externalfigure inside the \startcombination, I again get an > incorrect result. This is because (I think) that tikzpicture does not return a box. > In theory, the first version should work but some special settings > (using e.g. \useexternalfigure) may be required. I do not know why > the second version does work. Does anyone have an idea? Replace {\externalfigure[tikz.tmp]} with {\hbox{\input \jobname-tikz.tmp\relax}} I have noticed this \placefigure and I do not know if it is a bug or a feature. \placefigure expects you to give a box as a figure. Compare the output of \placefigure [here] {Left Fulushed} {This is a test} and \placefigure [here] {centered} {\hbox{This is a test}} Hans, will adding a \hbox explicitly to \placefigure break anything? On Tue, 9 Jan 2007, Hans Hagen wrote: > willy, what do i need to install to get this example running? You will need to install tikz from (http://sourceforge.net/projects/pgf/). The directory is not TDS complaint, so you may need to correct that before installing the tree. And of course, ignore Till Tantau's comments about ConTeXt on page 67-68 of the manual. He was working with stone age ConTeXt and still manged to get the whole thing working :-) And whenever you decide to overhaul the input mechanism for metapost, tikz has some nice ideas. Aditya