ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Fabrice Couvreur <fabrice1.couvreur@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Text around a figure in a framedtext
Date: Sat, 8 Aug 2015 09:41:20 +0200	[thread overview]
Message-ID: <CACyK-epo24vBP5NfnXRRwL6wTzA480V+NiWabTVUyS_mMstgDA@mail.gmail.com> (raw)
In-Reply-To: <2332FCB1-C027-4037-86D5-F02637FBA632@gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 3102 bytes --]

Hi Otared,
A small mistake on your part : do not write \input knuth.tex but \input
knuth.
Then I want the text in the first framedtext wrapped around the figure as in
the second.
Fabrice

2015-08-08 6:18 GMT+02:00 Otared Kavian <otared@gmail.com>:

> Hi,
>
> You should use the same width if you want to obtain the same result (by
> the way, you have to say also \stopframedtext in your source file):
>
> \startframedtext[width=\textwidth]{
> \placefigure[right,none]{}{%
>  \startMPcode
>   draw unitsquare scaled 2cm ;
>   \stopMPcode}
> \input knuth.tex }
> \stopframedtext
>
> Best regards: OK
>
> > On 08 Aug 2015, at 00:49, Fabrice Couvreur <fabrice1.couvreur@gmail.com>
> wrote:
> >
> > Hi,
> > Why the text does not move in the first framedtext like the second
> framedtext ?
> > Thank you.
> > Fabrice
> >
> > \definecolor[MyColorB][c=0.00, m=0.62, y=1.00, k=0.00]
> > \definecolor[MyColorA][.75(MyColorB,white)]
> >
> > \defineframedtext
> >   [MyText]
> >   [frame=off,
> >    background=MyFrame,
> >    width=\textwidth,
> >    location=right]
> >
> > \defineoverlay
> >   [MyFrame]
> >   [\useMPgraphic{MyFrame}]
> >
> > \definelabel
> >   [Définition]
> >   [headstyle=\bf\smallcaps]
> >
> > \startuseMPgraphic{MyFrame}
> >     path b ;
> >     picture p ;
> >     p := textext.rt("\white\Définition") ;
> >     p := p shifted (2BodyFontSize,OverlayHeight-ypart center
> p+.25ExHeight) ;
> >     b := boundingbox p leftenlarged .5EmWidth rightenlarged .5EmWidth ;
> >     fill OverlayBox withcolor \MPcolor{MyColorA} ;
> >     fill b withcolor \MPcolor{MyColorB} ;
> >     draw p ;
> > \stopuseMPgraphic
> >
> > \starttext
> > \startMyText
> > \placefigure[right,none]{}{%
> >  \startMPcode
> >   draw unitsquare scaled 2cm ;
> >   \stopMPcode}
> > \input knuth
> > \stopMyText
> >
> > \startframedtext{
> > \placefigure[right,none]{}{%
> >  \startMPcode
> >   draw unitsquare scaled 2cm ;
> >   \stopMPcode}
> > \input knuth}
> >
> > \stoptext
> >
> ___________________________________________________________________________________
> > 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
> >
> ___________________________________________________________________________________
>
>
> ___________________________________________________________________________________
> 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
>
> ___________________________________________________________________________________

[-- Attachment #1.2: Type: text/html, Size: 5349 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 bytes --]

___________________________________________________________________________________
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
___________________________________________________________________________________

  reply	other threads:[~2015-08-08  7:41 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-08-07 22:49 Fabrice Couvreur
2015-08-08  4:18 ` Otared Kavian
2015-08-08  7:41   ` Fabrice Couvreur [this message]
2015-08-08  8:40 ` Wolfgang Schuster
2015-08-09  9:21   ` Fabrice Couvreur
     [not found] <mailman.967.1439046228.2446.ntg-context@ntg.nl>
2015-08-09 23:11 ` Jeong Dal
2015-08-13 15:19   ` Fabrice Couvreur
2015-08-13 21:56     ` Fabrice Couvreur
2015-08-14  1:38     ` Rik Kabel
2015-08-14  7:49       ` Fabrice Couvreur

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=CACyK-epo24vBP5NfnXRRwL6wTzA480V+NiWabTVUyS_mMstgDA@mail.gmail.com \
    --to=fabrice1.couvreur@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).