From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/101238 Path: news.gmane.org!.POSTED!not-for-mail From: Otared Kavian Newsgroups: gmane.comp.tex.context Subject: Re: Strange behavior ! Date: Mon, 16 Jul 2018 09:56:15 +0200 Message-ID: <28649440-C530-4D69-97FD-3D6F0FC36058@gmail.com> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 (Mac OS X Mail 11.5 \(3445.9.1\)) Content-Type: multipart/mixed; boundary="===============0702970994024667455==" X-Trace: blaine.gmane.org 1531727697 11420 195.159.176.226 (16 Jul 2018 07:54:57 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 16 Jul 2018 07:54:57 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Mon Jul 16 09:54:53 2018 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 1feyLJ-0002mx-Ie for gctc-ntg-context-518@m.gmane.org; Mon, 16 Jul 2018 09:54:49 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 740FA43833; Mon, 16 Jul 2018 09:56:31 +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 S4DOi5bbZqDf; Mon, 16 Jul 2018 09:56:30 +0200 (CEST) Original-Received: from zapf.ntg.nl (localhost [IPv6:::1]) by zapf.ntg.nl (Postfix) with ESMTP id C89CF43818; Mon, 16 Jul 2018 09:56:30 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by zapf.ntg.nl (Postfix) with ESMTP id 4A87243818 for ; Mon, 16 Jul 2018 09:56:29 +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 Hu5YUBnclS4y for ; Mon, 16 Jul 2018 09:56:28 +0200 (CEST) Original-Received: from mail-wm0-f43.google.com (mail-wm0-f43.google.com [74.125.82.43]) (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 165CC43816 for ; Mon, 16 Jul 2018 09:56:18 +0200 (CEST) Original-Received: by mail-wm0-f43.google.com with SMTP id f21-v6so1969608wmc.5 for ; Mon, 16 Jul 2018 00:56:18 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:mime-version:subject:date:references:to:in-reply-to:message-id; bh=rVTuq4URl5xNzUDITlQaXkG6tKsnhdUApYUVGkzKAUM=; b=KrzFiLair0W7+th7M9VGD6e9a1TcTShFc96VmLLJElt2NFxyp/L9uXRpO4SePrP9JN jNTAzOOpWQ5nKr7B1ezLUEqQtJFJe0h6+dqieGKLYY6R3otKHbcKYmKeORHVxIUCu5he J8tSvF/LU0vV+eOb7g24SADLJVXZryTbvlDAQBfO87zkmqd8ni4mvETClAF2MCAYiZcp oTy+30G1wKzmTo4YDeg7wZHCFTC47xrKJHrh5xyjfQF2P03DXk+F3mFn4dkIetJ73zNb Dt9H8LqzfJGXcA/FqIzqLADyQza8MqnjldzfuFMtvNdSDiOAkzKme+hNfBrVG5YzZD7V b4pg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:mime-version:subject:date:references:to :in-reply-to:message-id; bh=rVTuq4URl5xNzUDITlQaXkG6tKsnhdUApYUVGkzKAUM=; b=Oj6EwSEDveST8lpMw0J7XO/79yRrzNYMYlfDejzOY+cSkQI84n6Le9leTOOwRB14UR cSgMPSgQx06hyVa0psYfmYi/ttg/oFa8dA3Gez/tc5MgasAJGPW57uUqi/xw07wxhaEm ChlW7lt/WUL8AJTWetIYzUeVQnCqr8LBqwjmllO4tUw3j8IwfU+sfef/XQDqkeBqBKNB Og4CSWOlS+A2hROMbF6xkhdk6OleAknOExty8CHNWdfe4DoajwOPfVitQhXWPmBZ92Wq noKYcDtjTjJ38ANTl2nu6ZAj8hNKCApCSpbLBtyBFtz64EvF6u6iY9YVaQH6MePRSVXu V3Zg== X-Gm-Message-State: AOUpUlEtDah1rfyVbCudgy9D/2oGu0jBgVxTrGLnSCBCruolP+gpAVdu kYSAbbFyltU3atqVUdDZX0r31QGq X-Google-Smtp-Source: AAOMgpe8+MNnn+3g/WnsaMGBd2r+gMervbZ/v/0lQA3yC5+29Adn+zbZK3AASWGJDFRVl+MZ5WCmHg== X-Received: by 2002:a1c:5b09:: with SMTP id p9-v6mr10127335wmb.0.1531727777433; Mon, 16 Jul 2018 00:56:17 -0700 (PDT) Original-Received: from ?IPv6:2a01:e34:ec02:4760:a422:b74:404:b4a3? ([2a01:e34:ec02:4760:a422:b74:404:b4a3]) by smtp.gmail.com with ESMTPSA id b198-v6sm16208596wme.11.2018.07.16.00.56.15 for (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 16 Jul 2018 00:56:16 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.3445.9.1) 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:101238 Archived-At: --===============0702970994024667455== Content-Type: multipart/alternative; boundary="Apple-Mail=_63ECEE7E-EE49-4199-8263-265C58D82FAE" --Apple-Mail=_63ECEE7E-EE49-4199-8263-265C58D82FAE Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 Hi Fabrice, This is because you define MyColorA, MyColorB but you don't define = MyColor and myColor: but you use these two colors in your MPgraphic. Best regards: OK > On 16 Jul 2018, at 00:03, Fabrice Couvreur = wrote: >=20 > Good evening, > In the code below, I get frames filled in black=E2=80=8B =E2=80=8B! > Thank you > Fabrice >=20 > \setupbodyfont [palatino,11pt] >=20 > \definecolor[MyColorB][c=3D0.00, m=3D0.62, y=3D1.00, k=3D0.00] > \definecolor[MyColorA][.75(MyColorB,white)] =20 >=20 > \defineframedtext > [MyText] > [frame=3Doff, > background=3DMyFrame, > width=3D\textwidth, > location=3Dright] >=20 > \defineoverlay > [MyFrame] > [\useMPgraphic{MyFrame}] >=20 > \definelabel > [D=C3=A9finition] > [headstyle=3D\bf\smallcaps] >=20 >=20 > \startuseMPgraphic{MyFrame} > picture p ; > p :=3D textext.rt(\MPstring{MyFrame}) ; > p :=3D p shifted (0,OverlayHeight-ypart center p) ; > fill OverlayBox leftenlarged .1TextWidth withcolor = \MPcolor{MyColor} ; > fill boundingbox p withcolor \MPcolor{myColor} ; > draw p withcolor white ; > setbounds currentpicture to OverlayBox ; > \stopuseMPgraphic >=20 >=20 > \starttext >=20 > \startMyText > \input knuth > \stopMyText >=20 > \startMyText > \input knuth > \stopMyText >=20 > \stoptext > = __________________________________________________________________________= _________ > If your question is of interest to others as well, please add an entry = to the Wiki! >=20 > maillist : ntg-context@ntg.nl / = http://www.ntg.nl/mailman/listinfo/ntg-context > webpage : http://www.pragma-ade.nl / http://context.aanhet.net > archive : https://bitbucket.org/phg/context-mirror/commits/ > wiki : http://contextgarden.net > = __________________________________________________________________________= _________ --Apple-Mail=_63ECEE7E-EE49-4199-8263-265C58D82FAE Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 Hi = Fabrice,

This is = because you define MyColorA, MyColorB but you don't define MyColor and = myColor: but you use these two colors in your MPgraphic.

Best regards: OK


On 16 Jul 2018, at 00:03, = Fabrice Couvreur <fabrice1.couvreur@gmail.com> wrote:

Good evening,
In the code below, I get frames filled = in black
=E2=80=8B =E2=80=8B
!

Thank you
Fabrice

\setupbodyfont [palatino,11pt]

\definecolor[MyColorB][c=3D0.00, m=3D0.62, = y=3D1.00, k=3D0.00]
\definecolor[MyColorA][.75(MyColorB,white)] 

\defineframedtext
   = [MyText]
   [frame=3Doff,
    background=3DMyFrame,
    width=3D\textwidth,
    location=3Dright]

\defineoverlay
   [MyFrame]
   [\useMPgraphic{MyFrame}]

\definelabel
   [D=C3=A9finition]
   [headstyle=3D\bf\smallcaps]


\startuseMPgraphic{MyFrame}
     picture p ;
     p :=3D = textext.rt(\MPstring{MyFrame}) ;
     = p :=3D p shifted (0,OverlayHeight-ypart center p) ;
     fill OverlayBox leftenlarged = .1TextWidth withcolor \MPcolor{MyColor} ;
     fill boundingbox p withcolor = \MPcolor{myColor} ;
     draw p = withcolor white ;
     setbounds = currentpicture to OverlayBox ;
\stopuseMPgraphic


\starttext

\startMyText
     \input = knuth
\stopMyText

\startMyText
     \input = knuth
\stopMyText

\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://context.aanhet.net
archive  : = https://bitbucket.org/phg/context-mirror/commits/
wiki     : http://contextgarden.net
_______________________________________________________________= ____________________

= --Apple-Mail=_63ECEE7E-EE49-4199-8263-265C58D82FAE-- --===============0702970994024667455== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly9jb250ZXh0LmFhbmhldC5uZXQKYXJjaGl2ZSAgOiBodHRwczovL2JpdGJ1Y2tldC5v cmcvcGhnL2NvbnRleHQtbWlycm9yL2NvbW1pdHMvCndpa2kgICAgIDogaHR0cDovL2NvbnRleHRn YXJkZW4ubmV0Cl9fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f --===============0702970994024667455==--