ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: "Mojca Miklavec" <mojca.miklavec.lists@gmail.com>
To: "mailing list for ConTeXt users" <ntg-context@ntg.nl>
Subject: Re: Margins around figures
Date: Sat, 8 Sep 2007 11:14:30 +0200	[thread overview]
Message-ID: <6faad9f00709080214x3de0babfiad7546da0dc607db@mail.gmail.com> (raw)
In-Reply-To: <20070907082341.GB6992@localhost>

On 9/7/07, Kumar Appaiah wrote:
> On Fri, Sep 07, 2007 at 09:18:30AM +0200, Oliver Buerschaper wrote:
> > Perhaps
> >
> > setbounds currentpicture to boundingbox currentpicture enlarged 5mm;
> >
> > at the end of your MetaPost drawing might do what you want?
>
> That's probably in the right direction, but the MetaPost newbie I am,
> I am unable to figure out the error:
>
> mpost seminar.mp
> This is MetaPost, Version 0.993 (Web2C 7.5.6)
> (seminar.mp (/usr/share/texmf-texlive/metapost/base/TEX.mp)
> (/usr/share/texmf-texlive/metapost/base/boxes.mp)
> >> boundingbox.currentpicture.enlarged1cm
> ! Improper `clip'.
> <to be read again>
>                    ;
> l.26 ...o boundingbox currentpicture enlarged 1cm;
>
> ?
>
> What error could this be? The line I added is:
>      setbounds currentpicture to boundingbox currentpicture enlarged 1cm;

Since plain metapost doesn't know about ConTeXt (metafun) extentions,
you need to:
- either add a line "input metafun ;" at the top of your metapost files
- or run "mptopdf seminar.mp" which will run metapost+create PDF
instead of running "mpost/mp seminar.mp" first and convert to PDF
later

When including a picture in ConTeXt, one options could also be to use:
\framed[frame=off,offset=1cm,strut=no,background=color,backgroundcolor=white]%
{\externalfigure[...]}
But that's slightly long and tedious, unless you write your own macro
wrapper around it.

Mojca
___________________________________________________________________________________
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  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


  parent reply	other threads:[~2007-09-08  9:14 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-09-07  4:16 Kumar Appaiah
2007-09-07  7:18 ` Oliver Buerschaper
2007-09-07  8:23   ` Kumar Appaiah
2007-09-07  9:27     ` Oliver Buerschaper
2007-09-07 10:31       ` Wolfgang Schuster
2007-09-07 17:46         ` Kumar Appaiah
2007-09-07 18:08           ` Kumar Appaiah
2007-09-08  9:14     ` Mojca Miklavec [this message]
2007-09-08 11:57       ` Kumar Appaiah

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=6faad9f00709080214x3de0babfiad7546da0dc607db@mail.gmail.com \
    --to=mojca.miklavec.lists@gmail.com \
    --cc=ntg-context@ntg.nl \
    /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).