From: Arun Mangalam <arun_mangalam@mac.com>
Subject: Stand-alone Graphic
Date: Tue, 16 Oct 2001 09:27:10 -0400 [thread overview]
Message-ID: <80E030A4-C239-11D5-A80B-00050207AA90@mac.com> (raw)
Hello,
While I was reading the Metafun manual, I found I could create a
MetaPost-based stand-alone pdf graphic [with the appropriate bounding
box] using
\startMPpage
...
\stopMPpage
My question is: is it possible and, if so, how do I create a stand-alone
pdf graphic for other graphics within ConTeXt? For example, I would like
to create a stand-alone graphic for the following code [instead of a PDF
page]:
\startbuffer[sample]
\framed
[align=middle,width=4cm,background=screen,frame=off]
{A \METAPOST\ clip is not the same as a video clip, although
we can use
\METAPOST\ to produce a video clip.}
\stopbuffer
\startMPclip{text clip}
clip currentpicture to fullcircle shifted (.5,.5)
xscaled \width yscaled \height ;
\stopMPclip
\startuseMPgraphic{clip outline}
draw fullcircle
xscaled \overlaywidth yscaled \overlayheight
withpen pencircle scaled 4mm
withcolor .625red ;
\stopuseMPgraphic
\starttext
\defineoverlay[clip outline][\useMPgraphic{clip outline}]
\placefigure
[here][fig:clipped text 2]
{A clipped buffer (text).}
{\framed
[background=clip outline,offset=overlay,frame=off]
{\clip
[nx=1,ny=1,mp=text clip]
{\externalfigure[sample][type=buffer,width=4cm]}}}
\stoptext
As you can see, the above is also from the MetaFun manual. :) ConTeXt
becomes better and better the more I find out about it.
Thank you for any help.
- Arun
PS. The reason for my question is, that I want to see if I can create an
MacOSX graphical program like xfig that uses ConTeXt. It would be both
educational for me in terms of understanding the Cocoa framework as well
as improve my understanding of ConTeXt.
next reply other threads:[~2001-10-16 13:27 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-10-16 13:27 Arun Mangalam [this message]
2001-10-16 16:20 ` Hans Hagen
2001-10-16 20:04 ` Arun Mangalam
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=80E030A4-C239-11D5-A80B-00050207AA90@mac.com \
--to=arun_mangalam@mac.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).