From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/95354 Path: news.gmane.org!not-for-mail From: Fabrice Couvreur Newsgroups: gmane.comp.tex.context Subject: Re: Baseline and framed Date: Wed, 6 Jul 2016 16:24:56 +0200 Message-ID: References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============4826274205198098637==" X-Trace: ger.gmane.org 1467815167 6017 80.91.229.3 (6 Jul 2016 14:26:07 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 6 Jul 2016 14:26:07 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Wed Jul 06 16:25:56 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 plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1bKnlz-0005BY-SM for gctc-ntg-context-518@m.gmane.org; Wed, 06 Jul 2016 16:25:55 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id C9053110F5; Wed, 6 Jul 2016 16:25:16 +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 W1T0TxzPeDIw; Wed, 6 Jul 2016 16:25:13 +0200 (CEST) Original-Received: from zapf.ntg.nl (localhost [IPv6:::1]) by zapf.ntg.nl (Postfix) with ESMTP id 685BA110F6; Wed, 6 Jul 2016 16:25:13 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id C48B9110F4 for ; Wed, 6 Jul 2016 16:25:12 +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 nGSQY-HfwBHQ for ; Wed, 6 Jul 2016 16:25:09 +0200 (CEST) Original-Received: from mail-it0-f42.google.com (mail-it0-f42.google.com [209.85.214.42]) (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 1ABB9110EE for ; Wed, 6 Jul 2016 16:24:59 +0200 (CEST) Original-Received: by mail-it0-f42.google.com with SMTP id f6so107033247ith.0 for ; Wed, 06 Jul 2016 07:24:59 -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=tKUlJYxji2r/lscosyZqKRM8UVgbSOK/v68bApmPWXM=; b=DHR8wvGpDZAsgcL20DCDV3T3pW/DJgu3ODc65AZLvdBLMYNy2rdh7ppBp5a4rSw65Z egRpOdEDMP6DlKeR5laJzy75/0p+p5OppJOb4/xfWRbTUVjR9X/GLp9tM5gBTyE1VXXp JQVXmCx7ygMu8A2vvtATapP6km6Nh860YL68SS+ve+1NSb+bvIOvW/8W+Gl34y2g38Yk BwJ2yMzzh0x2px4fJdyYPZIxMuz0oO0XLIGyQZVQJR3ex1hvSqGey4h/b3ppIly1REz5 szq1YM2cSd6m+Rf+I6Tf92QdCEVYzDkqKl+G5x7hFJceGKKA16Dao0IkYr8IBaIX4oWH bnbg== 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=tKUlJYxji2r/lscosyZqKRM8UVgbSOK/v68bApmPWXM=; b=EjhHe9r4tHvmnIFv3blny9yJ9Xgo1k3Y59W52uBtUpNvmLZv6HXwB2N4FbyFQPSAwG GEQuJ9GPgNorJUA76XXdRyVUH1c4+WsdSrJ+S9DZvtV1AxriGk5gp/Z03M6B3CS9Wxzn N+10qSiGjwq9QcY8aUvNHqe6cQbRBsxub6uS3UIOM7Hy946vmTtJcQqBNa367aPFv5md iL1rVA4ZxkUQ/Ufi6usHqeZimlB6L7RfYf6FHAqh4CJTOW37jImLoft2c5Wj7gBRHJio 3Pp8VT1utKZdnPSE++qh8C6fbGSrMhEyizpvFaydWHyDnY8aAT53cSXcvkZwEsjMaFgk +Mfw== X-Gm-Message-State: ALyK8tIuvTMVP8A8FyUzIEyvjLMVAEWS3p41R8buNWVrxenOyDTSKWd+t8SPgQddvAf0lSAK1V2htgo/jDWPfQ== X-Received: by 10.36.129.86 with SMTP id q83mr19562030itd.30.1467815096503; Wed, 06 Jul 2016 07:24:56 -0700 (PDT) Original-Received: by 10.64.10.2 with HTTP; Wed, 6 Jul 2016 07:24:56 -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:95354 Archived-At: --===============4826274205198098637== Content-Type: multipart/alternative; boundary=94eb2c06018e6c51eb0536f85553 --94eb2c06018e6c51eb0536f85553 Content-Type: text/plain; charset=UTF-8 Thank you Hans, the code would be : \unexpanded\def\HeadTitle#1#2% {\hbox to \hsize \bgroup \hfill \setupframed[offset=0.5em,frame=off] \inframed[width=fit,align=left,frame=off]{\darkred#1}% \inframed[width=fit,align=right,leftframe=on,rulethickness=4pt,framecolor=darkred]{#2}% \egroup} Thank you Hans, the code would be: Could I ask you how to have the chapter number is like the http://www.pragma-ade.nl/general/manuals/cont-enp.pdf book? This is a macro Metafun but I do not quite understand the mechanism. thank you, Fabrice 2016-07-06 15:03 GMT+02:00 Hans Hagen : > On 7/6/2016 1:37 PM, Fabrice Couvreur wrote: > >> >> Hello, >> In the manual, there is the macro below. >> Why theword "Matrice" is not on the same baseline as the number "1" ? >> thank you, >> Fabrice >> >> \unexpanded\def\HeadTitle#1#2% >> {\hbox to \hsize \bgroup >> \setupframed[height=1cm,offset=0.5em,frame=on] >> \framed[width=fit,align=left]{\darkred#1}% >> >> >> \framed[width=fit,align=right,leftframe=on,rulethickness=4pt,framecolor=darkred]{#2}% >> \egroup} >> >> \setuphead >> [chapter] >> [command=\HeadTitle] >> >> \starttext >> >> \startchapter >> [title={Matrice}] >> >> >> \stopchapter >> >> \stoptext >> > > fonts and such ... better use: > > \unexpanded\def\HeadTitle#1#2% > {\hbox to \hsize \bgroup > \inframed[width=fit,align=left]{\darkred#1}% > > > \inframed[width=fit,align=right,leftframe=on,rulethickness=4pt,framecolor=darkred]{#2}% > \egroup} > > ----------------------------------------------------------------- > 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/listinfo/ntg-context > webpage : http://www.pragma-ade.nl / http://tex.aanhet.net > archive : http://foundry.supelec.fr/projects/contextrev/ > wiki : http://contextgarden.net > > ___________________________________________________________________________________ --94eb2c06018e6c51eb0536f85553 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable
Thank you Hans, the code would be :
\unexpanded\def\HeadTitle#1#2%
=C2=A0 {\hbox to \hsize \bgroup
= =C2=A0=C2=A0 \hfill
=C2=A0=C2=A0 \setupframed[offset=3D0.5em,frame=3Doff= ]
=C2=A0=C2=A0 \inframed[width=3Dfit,align=3Dleft,frame=3Doff]{\darkred#= 1}%
=C2=A0=C2=A0 \inframed[width=3Dfit,align=3Dright,leftframe=3Don,rule= thickness=3D4pt,framecolor=3Ddarkred]{#2}%
=C2=A0=C2=A0 \egroup}

Thank you Hans, the code would be:
Could I ask you how to have the chapter number is like the http://www.pragma-ade.n= l/general/manuals/cont-enp.pdf book?
This is a macro Metafun= but I do not quite understand the mechanism
.
thank you,Fabrice


2016-07-06 15:0= 3 GMT+02:00 Hans Hagen <pragma@wxs.nl>:
On 7/6/2016 1:37 PM, Fabrice Couvreur wrote:

Hello,
In the manual, there is the macro below.
Why theword "Matrice" is not on the same baseline as the number &= quot;1" ?
thank you,
Fabrice

\unexpanded\def\HeadTitle#1#2%
=C2=A0 {\hbox to \hsize \bgroup
=C2=A0 =C2=A0\setupframed[height=3D1cm,offset=3D0.5em,frame=3Don]
=C2=A0 =C2=A0\framed[width=3Dfit,align=3Dleft]{\darkred#1}%

\framed[width=3Dfit,align=3Dright,leftframe=3Don,rulethickness=3D4pt,framec= olor=3Ddarkred]{#2}%
=C2=A0 =C2=A0 \egroup}

\setuphead
=C2=A0 =C2=A0[chapter]
=C2=A0 =C2=A0[command=3D\HeadTitle]

\starttext

\startchapter
=C2=A0 [title=3D{Matrice}]


\stopchapter

\stoptext

fonts and such ... better use:

\unexpanded\def\HeadTitle#1#2%
=C2=A0 {\hbox to \hsize \bgroup
=C2=A0 =C2=A0\inframed[width=3Dfit,align=3Dleft]{\darkred#1}%

\inframed[width=3Dfit,align=3Dright,leftframe=3Don,rulethickness=3D4pt,fram= ecolor=3Ddarkred]{#2}%
=C2=A0 =C2=A0\egroup}

-----------------------------------------------------------------
=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/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
___________________________________________________________________________= ________

--94eb2c06018e6c51eb0536f85553-- --===============4826274205198098637== 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= --===============4826274205198098637==--