From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/95857 Path: news.gmane.org!.POSTED!not-for-mail From: Mohammad Hossein Bateni Newsgroups: gmane.comp.tex.context Subject: Re: Question about \startcombination \stopcombination Date: Thu, 18 Aug 2016 14:31:48 -0400 Message-ID: References: <9eecfcfc-8826-6b57-1105-62d993a1c3f9@wxs.nl> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============3363584817469836398==" X-Trace: blaine.gmane.org 1471545159 14028 195.159.176.226 (18 Aug 2016 18:32:39 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Thu, 18 Aug 2016 18:32:39 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Thu Aug 18 20:32:31 2016 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from zapf.boekplan.nl ([5.39.185.232] helo=zapf.ntg.nl) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1baS7C-00037J-St for gctc-ntg-context-518@m.gmane.org; Thu, 18 Aug 2016 20:32:30 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 4112415243; Thu, 18 Aug 2016 20:32:07 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id Sf163dn-hMnB; Thu, 18 Aug 2016 20:32:05 +0200 (CEST) Original-Received: from zapf.ntg.nl (localhost [IPv6:::1]) by zapf.ntg.nl (Postfix) with ESMTP id 5DB7C15234; Thu, 18 Aug 2016 20:32:05 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 1E9741522F for ; Thu, 18 Aug 2016 20:32:04 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at zapf.boekplan.nl Original-Received: from zapf.ntg.nl ([127.0.0.1]) by localhost (zapf.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 7fzYULFp0S7z for ; Thu, 18 Aug 2016 20:32:02 +0200 (CEST) Original-Received: from mail-oi0-f65.google.com (mail-oi0-f65.google.com [209.85.218.65]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by zapf.ntg.nl (Postfix) with ESMTPS id 63EE01522E for ; Thu, 18 Aug 2016 20:31:51 +0200 (CEST) Original-Received: by mail-oi0-f65.google.com with SMTP id s207so4469909oie.0 for ; Thu, 18 Aug 2016 11:31:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=aMD/gF8rs4FbmuNSNX6Qv+viWto9q2AtbklEugNnNlw=; b=SoURrjDKSOm+oWW6uVJBOslMMEhTgg3niDrMBdsPWWe5qvKC38OCfTGNIjZTAAvIpF J9+SNLF9OaFzq5N1FsH6Opetb4CsT+2OgJ1LCri4nhWZK5Wtnc83LLdWY07f/2EmBbtc GtbLAxDqyaFTQQ4Y9i4hUOJHd3G9LeAEjYl6G7z4AeEsoL6ZnKNEhbyo7D3Dk5xlrVik 0W/5qPmcwh64VfzEnwS7lctaKI5N8VqKIYeRp8Cx9SxiMs+oNrBQH78FMXf088g2Vwxi JGPQCEXP4VDbmgRSvChmd1dbfFoklLWwCU6/ESinbVsu8tq+CWZkY+fVC1K/rGRkc9nJ dEhA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=aMD/gF8rs4FbmuNSNX6Qv+viWto9q2AtbklEugNnNlw=; b=LBk++FoZwZjrMcqxb2Xq8/exZ9VDNqBXGATcGvySb1YeBh/GF/JbGcSlny5pVB0bmh 8VK2tH5HrwKlBRBdVwmJl05bgwSuRznaZ1OYNt1eJxFAUfsfJjTVTyuy3L7DEtoxUH+l 6+Jmn2sWX2ouujTkqqwpXbEkBs97l4Ji1mM/SzbyRMVTE/3rcq6fsccEUsqH5KEBWFGM j2+BceC7bEMkdI04r7jR6cJAAJYRuPIdbFDSx5mo8zknxTb15mNAtxI1pQaRRorm3sGy 6TOstCoCioYsZtB59wr1wbmQs3bSpmMoCph1AybHW5CCjvFTnz3t1Xk+PnNG80VlEkE5 7sgw== X-Gm-Message-State: AEkoouuSARc5A4zgLIhJYK+2P8O2pYE2T27XPFJnk+zE26yM6XMHF58ST4vWSSHjbbwpvOJpNRe7/lYuags8Xg== X-Received: by 10.157.29.217 with SMTP id w25mr2138911otw.36.1471545109425; Thu, 18 Aug 2016 11:31:49 -0700 (PDT) Original-Received: by 10.157.45.77 with HTTP; Thu, 18 Aug 2016 11:31:48 -0700 (PDT) In-Reply-To: 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:95857 Archived-At: --===============3363584817469836398== Content-Type: multipart/alternative; boundary=001a113e35da84b5cc053a5ccb93 --001a113e35da84b5cc053a5ccb93 Content-Type: text/plain; charset=UTF-8 Hans, This is very good point. Is it an exception for start/start/combination or a more general difference? In fact, what are the differences between \X{y} and \startX y\stopX? A while back I ran into some weird issues and I figured that the latter inserts an \endgraf or something like that in the end. Is that right? Thanks, ~MHB On Thu, Aug 18, 2016 at 2:15 PM, Fabrice Couvreur < fabrice1.couvreur@gmail.com> wrote: > Hi Hans > Thank you, I do not know. > Fabrice > > 2016-08-18 19:46 GMT+02:00 Hans Hagen : > >> On 8/18/2016 7:12 PM, Fabrice Couvreur wrote: >> >>> Hello, >>> The use of \startcombination ... \stopcombination does not work with my >>> environment, I do not get all framed but only two and four >>> Thank you >>> Fabrice >>> >>> ######################################################### >>> \definecolor[MyColorA][r=0.8784, g=0.8784, b=0.8784] >>> >>> \defineframedtext >>> [MyFrame] >>> [before={\blank}, >>> after={\blank}, >>> frame=off, >>> background=MyFrame, >>> width=6cm, >>> height=fit, >>> style=small] >>> >>> \startuseMPgraphic{MyFrame} >>> path b; >>> picture p; >>> p := textext.rt("\tfx\white\framedtextparameter{Title}"); >>> p := p shifted (2BodyFontSize,OverlayHeight-ypart center >>> p+.25ExHeight); >>> b := boundingbox p leftenlarged .5EmWidth rightenlarged .5EmWidth ; >>> fill OverlayBox withcolor \MPcolor{MyColorA}; >>> fill b withcolor darkred ; >>> draw p; >>> setbounds currentpicture to boundingbox currentpicture enlarged 2mm ; >>> \stopuseMPgraphic >>> >>> \defineoverlay >>> [MyFrame] >>> [\useMPgraphic{MyFrame}] >>> >>> \starttext >>> >>> \startlinecorrection[blank] >>> \startmidaligned >>> \startcombination[2*2] >>> {\startMyFrame[Title=ALGO A] >>> One >>> \stopMyFrame}{} >>> {\startMyFrame[Title=ALGO B] >>> Two >>> \stopMyFrame}{} >>> {\startMyFrame[Title=ALGO C] >>> Three >>> \stopMyFrame}{} >>> {\startMyFrame[Title=ALGO D] >>> Four >>> \stopMyFrame}{} >>> \stopcombination >>> \stopmidaligned >>> \stoplinecorrection >>> >>> \stoptext >>> ######################################################### >>> >> >> \definecolor[MyColorA][r=0.8784, g=0.8784, b=0.8784] >> >> \defineframedtext >> [MyFrame] >> [frame=off, >> background=MyFrame, >> width=6cm, >> height=fit, >> style=small] >> >> \startuseMPgraphic{MyFrame} >> path b; >> picture p; >> p := textext.rt("\tfx\white\framedtextparameter{Title}"); >> p := p shifted (2BodyFontSize,OverlayHeight-ypart center >> p+.25ExHeight); >> b := boundingbox p leftenlarged .5EmWidth rightenlarged .5EmWidth ; >> fill OverlayBox withcolor "MyColorA" ; >> fill b withcolor darkred ; >> draw p ; >> setbounds currentpicture to boundingbox currentpicture enlarged 2mm ; >> \stopuseMPgraphic >> >> \defineoverlay >> [MyFrame] >> [\useMPgraphic{MyFrame}] >> >> \starttext >> >> \startcombination[2*2] >> {\MyFrame[Title=ALGO A]{One}} {} >> {\MyFrame[Title=ALGO B]{Two}} {} >> {\MyFrame[Title=ALGO C]{Three}} {} >> {\MyFrame[Title=ALGO D]{Four}} {} >> \stopcombination >> >> \stoptext >> >> the start/stop variant ignores the width >> >> ----------------------------------------------------------------- >> Hans Hagen | PRAGMA ADE >> Ridderstraat 27 | 8061 GH Hasselt | The Netherlands >> tel: 038 477 53 69 | www.pragma-ade.nl | 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/list >> info/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 > ____________________________________________________________ > _______________________ > --001a113e35da84b5cc053a5ccb93 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Hans,

This is very good point.=C2=A0 Is= it an exception for start/start/combination or a more general difference?= =C2=A0 In fact, what are the differences between \X{y} and \startX y\stopX?= =C2=A0 A while back I ran into some weird issues and I figured that the lat= ter inserts an \endgraf or something like that in the end.=C2=A0 Is that ri= ght?

Thanks,
~MHB

On Thu, Aug 18, 2016 at 2:1= 5 PM, Fabrice Couvreur <fabrice1.couvreur@gmail.com> wrote:
Hi Hans
Thank you, I do not know.
Fabric= e

2016-08= -18 19:46 GMT+02:00 Hans Hagen <pragma@wxs.nl>:
On 8/18/2016 7:12 PM, Fabrice Couvreur wrote:
Hello,
The use of \startcombination ... \stopcombination does not work with my
environment, I do not get all framed but only two and four
Thank you
Fabrice

#########################################################
\definecolor[MyColorA][r=3D0.8784, g=3D0.8784, b=3D0.8784]

\defineframedtext
=C2=A0 [MyFrame]
=C2=A0 [before=3D{\blank},
=C2=A0 =C2=A0after=3D{\blank},
=C2=A0 =C2=A0frame=3Doff,
=C2=A0 =C2=A0background=3DMyFrame,
=C2=A0 =C2=A0width=3D6cm,
=C2=A0 =C2=A0height=3Dfit,
=C2=A0 =C2=A0style=3Dsmall]

\startuseMPgraphic{MyFrame}
=C2=A0path b;
=C2=A0picture p;
=C2=A0p :=3D textext.rt("\tfx\white\framedtextparameter{Title}&qu= ot;);
=C2=A0p :=3D p shifted (2BodyFontSize,OverlayHeight-ypart center p+.25= ExHeight);
=C2=A0b :=3D boundingbox p leftenlarged .5EmWidth rightenlarged .5EmWidth ;=
=C2=A0fill OverlayBox withcolor \MPcolor{MyColorA};
=C2=A0fill b withcolor darkred ;
=C2=A0draw p;
=C2=A0setbounds currentpicture to boundingbox currentpicture enlarged 2mm ;=
\stopuseMPgraphic

\defineoverlay
=C2=A0 [MyFrame]
=C2=A0 [\useMPgraphic{MyFrame}]

\starttext

\startlinecorrection[blank]
\startmidaligned
\startcombination[2*2]
{\startMyFrame[Title=3DALGO A]
=C2=A0One
=C2=A0\stopMyFrame}{}
{\startMyFrame[Title=3DALGO B]
Two
\stopMyFrame}{}
{\startMyFrame[Title=3DALGO C]
Three
\stopMyFrame}{}
{\startMyFrame[Title=3DALGO D]
Four
\stopMyFrame}{}
\stopcombination
\stopmidaligned
\stoplinecorrection

\stoptext
#########################################################

\definecolor[MyColorA][r=3D0.8784, g=3D0.8784, b=3D0.8784]

\defineframedtext
=C2=A0 [MyFrame]
=C2=A0 [frame=3Doff,
=C2=A0 =C2=A0background=3DMyFrame,
=C2=A0 =C2=A0width=3D6cm,
=C2=A0 =C2=A0height=3Dfit,
=C2=A0 =C2=A0style=3Dsmall]

\startuseMPgraphic{MyFrame}
=C2=A0 =C2=A0 path b;
=C2=A0 =C2=A0 picture p;
=C2=A0 =C2=A0 p :=3D textext.rt("\tfx\white\framedtextparameter{T= itle}");
=C2=A0 =C2=A0 p :=3D p shifted (2BodyFontSize,OverlayHeight-ypart cent= er p+.25ExHeight);
=C2=A0 =C2=A0 b :=3D boundingbox p leftenlarged .5EmWidth rightenlarged .5E= mWidth ;
=C2=A0 =C2=A0 fill OverlayBox withcolor "MyColorA" ;
=C2=A0 =C2=A0 fill b withcolor darkred ;
=C2=A0 =C2=A0 draw p ;
=C2=A0 =C2=A0 setbounds currentpicture to boundingbox currentpicture enlarg= ed 2mm ;
\stopuseMPgraphic

\defineoverlay
=C2=A0 [MyFrame]
=C2=A0 [\useMPgraphic{MyFrame}]

\starttext

=C2=A0 =C2=A0 \startcombination[2*2]
=C2=A0 =C2=A0 =C2=A0 =C2=A0 {\MyFrame[Title=3DALGO A]{One}}=C2=A0 =C2=A0{}<= br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 {\MyFrame[Title=3DALGO B]{Two}}=C2=A0 =C2=A0{}<= br> =C2=A0 =C2=A0 =C2=A0 =C2=A0 {\MyFrame[Title=3DALGO C]{Three}} {}
=C2=A0 =C2=A0 =C2=A0 =C2=A0 {\MyFrame[Title=3DALGO D]{Four}}=C2=A0 {}
=C2=A0 =C2=A0 \stopcombination

\stoptext

the start/stop variant ignores the width

-----------------------------------------------------------------=
=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 =C2=A0 =C2=A0tel: 038 477 53 69 | www.pragma-ade.nl | www.p= ragma-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/listin= fo/ntg-context
webpage=C2=A0 : http://www.pragma-ade.nl / http://tex.aanhet.net
archive=C2=A0 : http://foundry.supelec.fr/project= s/contextrev/
wiki=C2=A0 =C2=A0 =C2=A0: http://contextgarden.net
_________________________________________________________________= __________________


______________________________________________________= _____________________________
If your question is of interest to others as well, please add an entry to t= he Wiki!

maillist : ntg-context@ntg.nl / <= a href=3D"http://www.ntg.nl/mailman/listinfo/ntg-context" rel=3D"noreferrer= " target=3D"_blank">http://www.ntg.nl/mailman/listinfo/ntg-context=
webpage=C2=A0 : http://www.pragma-ade.nl / http://tex.aanhet.net
archive=C2=A0 : http://foundry.supelec.fr/project= s/contextrev/
wiki=C2=A0 =C2=A0 =C2=A0: http://contextgarden.net
_________________________________________________________________= __________________

--001a113e35da84b5cc053a5ccb93-- --===============3363584817469836398== 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= --===============3363584817469836398==--