From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/92452 Path: news.gmane.org!not-for-mail From: Fabrice Couvreur Newsgroups: gmane.comp.tex.context Subject: Re: About graphictext macro (Metafun) Date: Fri, 28 Aug 2015 00:09:12 +0200 Message-ID: References: <55DEBECB.4@wxs.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0506034024==" X-Trace: ger.gmane.org 1440713423 15538 80.91.229.3 (27 Aug 2015 22:10:23 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 27 Aug 2015 22:10:23 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Fri Aug 28 00:10:08 2015 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([5.39.185.229]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZV5Mz-0000bu-4Q for gctc-ntg-context-518@m.gmane.org; Fri, 28 Aug 2015 00:10:07 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 364FE101F6 for ; Fri, 28 Aug 2015 00:09:59 +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 l1gqXhi66sb7 for ; Fri, 28 Aug 2015 00:09:57 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id BA8411023C for ; Fri, 28 Aug 2015 00:09:23 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 0991E101FE for ; Fri, 28 Aug 2015 00:09:18 +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 HltjJfLx6NWo for ; Fri, 28 Aug 2015 00:09:16 +0200 (CEST) Original-Received: from filter3-ams.mf.surf.net (filter3-ams.mf.surf.net [192.87.102.71]) by balder.ntg.nl (Postfix) with ESMTP id 37EBF101F6 for ; Fri, 28 Aug 2015 00:09:16 +0200 (CEST) Original-Received: from mail-ig0-x22a.google.com (mail-ig0-x22a.google.com [IPv6:2607:f8b0:4001:c05::22a]) by filter3-ams.mf.surf.net (8.14.4/8.14.4/Debian-4) with ESMTP id t7RM9DUM015521 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 28 Aug 2015 00:09:14 +0200 Original-Received: by igui7 with SMTP id i7so5241732igu.1 for ; Thu, 27 Aug 2015 15:09:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=Qf7oeFV4VXiVeyt8OfY3pVOjjU8eNrKUoWQbk6TDfdU=; b=NyvFXpYGWLEiJaUb62iDx/ldqW4aZAncV9mi1q2JmsD59R2EKpvkqBisSR0emGsbSU YzGxUYC3bufWBqksWJsRrMubSeEGR5Jb1UmKcecB+kNNKuotBgYe57ChRK4b+xZ8EBfj jL99oWJ/N1DcDqAT2bJu8GozAhm05qmedoayrNanVf7fHxfIYmPWdahWYigFFmMRLPVE FQEY0Z4aAvnHsjPUrt8L3bssh5KUqdmoJQs0j6gvTgRMqmm5HoyD7rR/yT5hYwP2Dbza SVJ2AZ1IqiximLPTiqUTG2OkkoKmvTHkFvyizh/0Vzx+AwRd76jrcx9MC/3bfp+kU9wJ oy/A== X-Received: by 10.50.92.99 with SMTP id cl3mr817677igb.48.1440713353032; Thu, 27 Aug 2015 15:09:13 -0700 (PDT) Original-Received: by 10.64.236.2 with HTTP; Thu, 27 Aug 2015 15:09:12 -0700 (PDT) In-Reply-To: X-Bayes-Prob: 0.0001 (Score 0, tokens from: ntg-context@ntg.nl, base:default, @@RPTN) X-CanIt-Geo: ip=2607:f8b0:4001:c05::22a; country=US; region=Iowa; city=Council Bluffs; latitude=41.2619; longitude=-95.8608; http://maps.google.com/maps?q=41.2619,-95.8608&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 03P9W9ePJ - 78f76b05ca82 - 20150828 (trained as not-spam) Received-SPF: pass (filter3-ams.mf.surf.net: domain of fabrice1.couvreur@gmail.com designates 2607:f8b0:4001:c05::22a as permitted sender) receiver=filter3-ams.mf.surf.net; client-ip=2607:f8b0:4001:c05::22a; envelope-from=; helo=mail-ig0-x22a.google.com; identity=mailfrom X-Scanned-By: CanIt (www . roaringpenguin . com) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.16 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" Xref: news.gmane.org gmane.comp.tex.context:92452 Archived-At: --===============0506034024== Content-Type: multipart/alternative; boundary=047d7b10cf2da17a41051e52371b --047d7b10cf2da17a41051e52371b Content-Type: text/plain; charset=UTF-8 Hi Hans, I installed pstoedit : root@debian:/home/fab# dpkg --status pstoedit Package: pstoedit Status: install ok installed Priority: optional Section: graphics Installed-Size: 662 Maintainer: Roland Stigge Architecture: amd64 Source: pstoedit (3.62-2) Version: 3.62-2+b3 Depends: libc6 (>= 2.2.5), libpstoedit0c2a, libstdc++6 (>= 4.1.1), ghostscript Suggests: xfig | ivtools-bin | tgif | transfig Description: PostScript and PDF files to editable vector graphics converter pstoedit converts Postscript and PDF files to various editable vector graphic formats including tgif, xfig, PDF graphics, gnuplot format, idraw, MetaPost, GNU Metafile, PIC, Kontour and flattened PostScript. Homepage: http://www.pstoedit.net/ root@debian:/home/fab# I compiled the file as this : "context test.tex" but it is still empty. Thanks, Fabrice \setuppagenumbering[location=] \setupcolors [state=start] \setMPtext{text}{MATH\'{E}MATIQUES} \starttext \startuseMPgraphic{test} picture pic ; pic := image(graphictext \MPstring{text} withdrawcolor red withpen pencircle scaled 1pt ; ) ; \stopuseMPgraphic \stoptext 2015-08-27 10:23 GMT+02:00 Fabrice Couvreur : > Hi Hans, > > Do you have pstoedit installed ? > > > root@debian:/home/fab# apt-cache search pstoedit > libpstoedit0c2a - PostScript to editable vector graphics library (runtime > files) > root@debian:/home/fab# > > I compile the file test.tex with context test.tex > Fabrice > > 2015-08-27 9:39 GMT+02:00 Hans Hagen : > >> On 8/26/2015 7:12 PM, Fabrice Couvreur wrote: >> >>> Hi, >>> I try to understand how this macro by testing a simple example. Why pdf >>> file is empty? >>> This question follows my question Cover page (Metafun) >>> http://www.ntg.nl/pipermail/ntg-context/2015/083078.html >>> Thank you. >>> >>> \setuppagenumbering[location=] >>> >>> \setupcolors >>> [state=start] >>> >>> \setMPtext{text}{MATHEMATIQUES} >>> >>> >>> \starttext >>> \startuseMPgraphic{test} >>> picture pic ; >>> pic := image(graphictext \MPstring{text} >>> withdrawcolor red >>> withpen pencircle scaled 1pt ; ) ; >>> addto currentpicture also pic ; >>> \stopuseMPgraphic >>> \stoptext >>> >> >> Do you have pstoedit installed? >> >> Anyway, there is a new mechanism that doesn't depend on additional >> programs: >> >> % outlinetext (text) transformations ; >> % outlinetext.d (text) (draw options) transformations ; >> % outlinetext.f (text) (fill options) transformations ; >> % outlinetext.b (text) (draw options) (fill options) transformations ; >> % outlinetext.r (text) (fill options) (draw options) transformations ; >> >> \starttext >> >> \startMPdefinitions >> let graphictext = new_graphictext ; >> \stopMPdefinitions >> >> \startMPpage >> >> draw outlinetext.b >> ("\framed[align=normal]{\input{tufte}}") >> (withcolor .5white) >> (withcolor red withpen pencircle scaled 1/10) >> xsized 10cm ; >> >> \stopMPpage >> >> \startMPpage >> >> draw outlinetext.r >> ("\framed[align=normal]{\input{tufte}}") >> (withcolor red withpen pencircle scaled 1/10) >> (withcolor .5white) >> xsized 10cm ; >> >> \stopMPpage >> >> \startMPpage >> >> draw outlinetext.d >> ("\framed[align=normal]{\input{tufte}}") >> (withcolor .5white) >> xsized 10cm ; >> >> \stopMPpage >> >> \startMPpage >> >> picture p ; p := outlinetext.p("PX") ; >> >> for i within p : >> draw i withcolor red withpen pencircle scaled 1/10 ; >> endfor ; >> >> \stopMPpage >> >> \stoptext >> >> >> >> ----------------------------------------------------------------- >> Hans Hagen | PRAGMA ADE >> Ridderstraat 27 | 8061 GH Hasselt | The Netherlands >> tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com >> | www.pragma-pod.nl >> ----------------------------------------------------------------- >> >> ___________________________________________________________________________________ >> 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 >> >> ___________________________________________________________________________________ > > > --047d7b10cf2da17a41051e52371b Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hi Hans,
I installed pstoedit :

root@debian:/home/fab# dpkg --status pstoedit
Pa= ckage: pstoedit
Status: install ok installed
Priority: optional
Se= ction: graphics
Installed-Size: 662
Maintainer: Roland Stigge <stigge@antcom.de>
Architecture: = amd64
Source: pstoedit (3.62-2)
Version: 3.62-2+b3
Depends: libc6 = (>=3D 2.2.5), libpstoedit0c2a, libstdc++6 (>=3D 4.1.1), ghostscriptSuggests: xfig | ivtools-bin | tgif | transfig
Description: PostScript= and PDF files to editable vector graphics converter
=C2=A0pstoedit conv= erts Postscript and PDF files to various editable
=C2=A0vector graphic f= ormats including tgif, xfig, PDF graphics, gnuplot format,
=C2=A0idraw, = MetaPost, GNU Metafile, PIC, Kontour and flattened PostScript.
Homepage:= http://www.pstoedit.net/
root@= debian:/home/fab#

I compi= led the file as this : &quo= t;context test.tex" but it is still empty.
Thanks,
Fabrice


\setuppagenumbering[location=3D]

\setupcolors=C2=A0 [state=3Dstart]

\setMPtext{text}{MATH\'{E}MATIQUES}
=

\starttext
\startuseMPgraphic{test}
picture pic ;
pic :=3D= image(graphictext \MPstring{text}
withdrawcolor red
withpen pencirc= le scaled 1pt ; ) ;
\stopuseMPgraphic
\stoptext


=

2015-08= -27 10:23 GMT+02:00 Fabrice Couvreur <fabrice1.couvreur@gmail.co= m>:
Hi Han= s,

Do you have pst= oedit installed ?

root@debian:/home/fab# apt-cache sea= rch pstoedit
libpstoedit0c2a - PostScript to editable vector graphics li= brary (runtime files)
root@debian:/home/fab#

<= span>I compile the file test.tex=C2=A0 with=C2= =A0 context test.tex
Fabrice=

2015-08-27 9:39 GMT+02= :00 Hans Hagen <pragma@wxs.nl>:
Hi,
I try to understand how this macro by testing a simple example. Why pdf
file is empty?
This question follows my question Cover page (Metafun)
http://www.ntg.nl/pipermail/ntg-context/2015= /083078.html
Thank you.

\setuppagenumbering[location=3D]

\setupcolors
=C2=A0 =C2=A0[state=3Dstart]

\setMPtext{text}{MATHEMATIQUES}


\starttext
\startuseMPgraphic{test}
picture pic ;
pic :=3D image(graphictext \MPstring{text}
withdrawcolor red
withpen pencircle scaled 1pt ; ) ;
addto currentpicture also pic ;
\stopuseMPgraphic
\stoptext

Do you have pstoedit installed?

Anyway, there is a new mechanism that doesn't depend on additional prog= rams:

% outlinetext=C2=A0 =C2=A0(text) transformations ;
% outlinetext.d (text) (draw options) transformations ;
% outlinetext.f (text) (fill options) transformations ;
% outlinetext.b (text) (draw options) (fill options) transformations ;
% outlinetext.r (text) (fill options) (draw options) transformations ;

\starttext

\startMPdefinitions
=C2=A0 =C2=A0 let graphictext =3D new_graphictext ;
\stopMPdefinitions

\startMPpage

=C2=A0 =C2=A0 draw outlinetext.b
=C2=A0 =C2=A0 =C2=A0 =C2=A0 ("\framed[align=3Dnormal]{\input{tufte}}&q= uot;)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 (withcolor .5white)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 (withcolor red withpen pencircle scaled 1/10) =C2=A0 =C2=A0 =C2=A0 =C2=A0 xsized 10cm ;

\stopMPpage

\startMPpage

=C2=A0 =C2=A0 draw outlinetext.r
=C2=A0 =C2=A0 =C2=A0 =C2=A0 ("\framed[align=3Dnormal]{\input{tufte}}&q= uot;)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 (withcolor red withpen pencircle scaled 1/10) =C2=A0 =C2=A0 =C2=A0 =C2=A0 (withcolor .5white)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 xsized 10cm ;

\stopMPpage

\startMPpage

=C2=A0 =C2=A0 draw outlinetext.d
=C2=A0 =C2=A0 =C2=A0 =C2=A0 ("\framed[align=3Dnormal]{\input{tufte}}&q= uot;)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 (withcolor .5white)
=C2=A0 =C2=A0 =C2=A0 =C2=A0 xsized 10cm ;

\stopMPpage

\startMPpage

=C2=A0 =C2=A0 picture p ; p :=3D outlinetext.p("PX") ;

=C2=A0 =C2=A0 for i within p :
=C2=A0 =C2=A0 =C2=A0 =C2=A0 draw i withcolor red withpen pencircle scaled 1= /10 ;
=C2=A0 =C2=A0 endfor ;

\stopMPpage

\stoptext



-----------------------------------------------------------------
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 H= ans Hagen | PRAGMA ADE
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 Ridderstraat 27 | 8061 GH = Hasselt | The Netherlands
=C2=A0 =C2=A0 tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com=
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0| www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________= ________
If your question is of interest to others as well, please add an entry to t= he Wiki!

maillist : ntg-cont= ext@ntg.nl / http://www.ntg.nl/mailman/listinfo/nt= g-context
webpage=C2=A0 : http://www.pragma-ade.nl / http://tex.aanhet.net
archive=C2=A0 : http://foundry.supelec.fr/projects/con= textrev/
wiki=C2=A0 =C2=A0 =C2=A0: http://contextgarden.net
___________________________________________________________________________= ________


--047d7b10cf2da17a41051e52371b-- --===============0506034024== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly90ZXguYWFuaGV0Lm5ldAphcmNoaXZlICA6IGh0dHA6Ly9mb3VuZHJ5LnN1cGVsZWMu ZnIvcHJvamVjdHMvY29udGV4dHJldi8Kd2lraSAgICAgOiBodHRwOi8vY29udGV4dGdhcmRlbi5u ZXQKX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX18= --===============0506034024==--