From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/63789 Path: news.gmane.org!not-for-mail From: luigi scarso Newsgroups: gmane.comp.tex.context Subject: Re: Creating graphic file instead of PDF Date: Sun, 21 Nov 2010 10:51:13 +0100 Message-ID: References: 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: dough.gmane.org 1290333099 5801 80.91.229.12 (21 Nov 2010 09:51:39 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 21 Nov 2010 09:51:39 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Sun Nov 21 10:51:35 2010 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PK6a3-0001Tn-5J for gctc-ntg-context-518@m.gmane.org; Sun, 21 Nov 2010 10:51:31 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 147A2CA852; Sun, 21 Nov 2010 10:51:30 +0100 (CET) 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 nO62xjrl1S3k; Sun, 21 Nov 2010 10:51:29 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 44469CA843; Sun, 21 Nov 2010 10:51:27 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 19B04CA843 for ; Sun, 21 Nov 2010 10:51:26 +0100 (CET) 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 fFb7N5j67iAL for ; Sun, 21 Nov 2010 10:51:15 +0100 (CET) Original-Received: from filter1-ams.mf.surf.net (filter1-ams.mf.surf.net [192.87.102.69]) by balder.ntg.nl (Postfix) with ESMTP id E61F8CA83E for ; Sun, 21 Nov 2010 10:51:14 +0100 (CET) Original-Received: from mail-qw0-f41.google.com (mail-qw0-f41.google.com [209.85.216.41]) by filter1-ams.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id oAL9pE94010196 for ; Sun, 21 Nov 2010 10:51:14 +0100 Original-Received: by qwi2 with SMTP id 2so1448708qwi.14 for ; Sun, 21 Nov 2010 01:51:13 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:content-type; bh=JwbJe6O+McyjYpC93wjAKQ8i43iKw+bF7FmyIGm+8/8=; b=K2pmOiOEpVLxrz3qMcHmxCaS7Nj5yHsY9/D6MJWIDSITOZDuaI+h0VncjniGEllpIl MDUMHjr57tOdJqVbIgP44SYB6n8yzTpMo+LQocuNhFP/Nl4ipcdvlBeKVYwV8WgGLZXN NBFEmis1GR4hAOQjx8atfKMTSVY2J5FwohDpY= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=QYvB1OPFF9khS7//tFEge1mtbvobwyblkdPdWNINXJCRIuGtsJuQJtL1rMNol8NARG yJ0MMwUdZZ82h5X/4ozygoo6LHlx4o49n2C3/4DdbTzZwTh1wemfOJmY4hogD59uer+b rx92+gzA3OBnHVzFiVB/+rfbRuhfvPhgWubjM= Original-Received: by 10.229.189.134 with SMTP id de6mr3868180qcb.51.1290333073668; Sun, 21 Nov 2010 01:51:13 -0800 (PST) Original-Received: by 10.229.231.198 with HTTP; Sun, 21 Nov 2010 01:51:13 -0800 (PST) In-Reply-To: X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=209.85.216.41; country=US; region=CA; city=Mountain View; postalcode=94043; latitude=37.4192; longitude=-122.0574; metrocode=807; areacode=650; http://maps.google.com/maps?q=37.4192,-122.0574&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 06DxJPeMx - 162a3a562acc - 20101121 X-Scanned-By: CanIt (www . roaringpenguin . com) on 192.87.102.69 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 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 Xref: news.gmane.org gmane.comp.tex.context:63789 Archived-At: On Sun, Nov 21, 2010 at 10:38 AM, Cecil Westerhof wrote: > 2010/11/21 luigi scarso : >>>>> I am making flowcharts with ConTeXt. Because the flowcharts have to be >>>>> included in other documents, I would like to make graphic files (jpeg, >>>>> png, ...). Also not bigger as needed to represent the flowchart. >>>>> Can this be done. >>>> Just convert the pdf in jpeg with (for example) ghostscript. >>> >>> This works, but the problem is that I get an image the size of an A4. >>> This is mostly whitespace. Is it not possible to only get the used >>> part? >> Maybe wrap your flowcharts-code in \startTEXpage ... \stopTEXpage, ie >> something like this >> \starttext >> \startTEXpage >> Put your flowcharts-code here... >> \stopTEXpage >> \stoptext > > Works like a charm. Thanks. > > By the way instead of gs from ghostscript, you can also use convert > from Image Magick. or GraphicsMagick, but as far as I know they still depend to ghostscript. An independent way is to convert the pdf with pdftoppm and then convert again the ppm to png/jpeg. -- luigi ___________________________________________________________________________________ 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 ___________________________________________________________________________________