From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/35400 Path: news.gmane.org!not-for-mail From: Peter Rolf Newsgroups: gmane.comp.tex.context Subject: Re: frames in ConTeXt and metafun Date: Thu, 12 Jul 2007 10:04:05 +0200 Message-ID: <4695E075.7010907@gmx.net> References: <5FEB6878-A8F6-4FD6-BA44-98FE6D575CE7@uni-bonn.de> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------010105050404070807040402" X-Trace: sea.gmane.org 1184227461 31880 80.91.229.12 (12 Jul 2007 08:04:21 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 12 Jul 2007 08:04:21 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Thu Jul 12 10:04:18 2007 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by lo.gmane.org with esmtp (Exim 4.50) id 1I8ter-00062x-Uz for gctc-ntg-context-518@m.gmane.org; Thu, 12 Jul 2007 10:04:18 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id D891E202A3; Thu, 12 Jul 2007 10:04:16 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 23074-03-8; Thu, 12 Jul 2007 10:04:08 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 1F24D202A8; Thu, 12 Jul 2007 10:04:08 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 28339202A8 for ; Thu, 12 Jul 2007 10:04:06 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 23074-03-7 for ; Thu, 12 Jul 2007 10:04:02 +0200 (CEST) Original-Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by ronja.ntg.nl (Postfix) with SMTP id CA214202A3 for ; Thu, 12 Jul 2007 10:04:02 +0200 (CEST) Original-Received: (qmail invoked by alias); 12 Jul 2007 08:04:02 -0000 Original-Received: from i577B8FAF.versanet.de (EHLO [192.168.1.3]) [87.123.143.175] by mail.gmx.net (mp055) with SMTP; 12 Jul 2007 10:04:02 +0200 X-Authenticated: #24293357 X-Provags-ID: V01U2FsdGVkX1959/EleZB5N+lOnzEiMpMjxmkp4WRbeiE9xe6k0g JbIXYuW9/2BtwM User-Agent: Thunderbird 2.0.0.4 (Windows/20070604) In-Reply-To: <5FEB6878-A8F6-4FD6-BA44-98FE6D575CE7@uni-bonn.de> X-Enigmail-Version: 0.95.2 X-Y-GMX-Trusted: 0 X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:35400 Archived-At: This is a multi-part message in MIME format. --------------010105050404070807040402 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Hi Thomas, Thomas A. Schmitz schrieb: > This is a very small cosmetic problem, but it bugs me: I'm preparing > a background for a presentation, and I want a frame with a > transparent color to appear on every slide, so I define an overlay > and use metapost. I also want to frame some text elements, so I use a > \framed. The problem is that in the \framed, the lines of the frame > overlap at the edges, so with a transparent color, the corners are > slightly darker. The minimal example below shows the problem. Any > solution? Is it possible to have the frame around \framed drawn by > metapost? > sure (see attachment). Greetings, Peter > Thanks! > > Thomas > > > %%%%% MINIMAL EXAMPLE %%%%%% > > \setupcolors[state=start] > > \definecolor [MyFrameColor] [b=.55, t=.5, a=1] > > \starttext > > \startuseMPgraphic{fancyframe} > draw unitsquare > xyscaled(8cm,8cm) > withpen pencircle scaled 4pt > withcolor \MPcolor{MyFrameColor} ; > \stopuseMPgraphic > > \useMPgraphic{fancyframe} > > \framed > [rulethickness=4pt,framecolor=MyFrameColor,height=8cm,width=8cm]{\strut} > > \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 : https://foundry.supelec.fr/projects/contextrev/ > wiki : http://contextgarden.net > ___________________________________________________________________________________ > --------------010105050404070807040402 Content-Type: text/plain; name="frame.tex" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="frame.tex" \setupcolors[state=start] \definecolor [MyFrameColor] [b=.55, t=.5, a=1] \startuniqueMPgraphic{fancyframe}{linewidth,radius,color} begingroup save c, lw ; color c ; c:= \MPvar{color} ; lw:= \MPvar{linewidth} ; draw unitsquare xyscaled(OverlayWidth-lw,OverlayHeight-lw) smoothed \MPvar{radius} withpen pencircle scaled lw withcolor c ; endgroup ; \stopuniqueMPgraphic \defineoverlay[fancyframe] [\uniqueMPgraphic{fancyframe}{linewidth=4pt,radius=5pt,color=MyFrameColor}] \presetlocalframed[fancy] \setuplocalframed[fancy] [frame=off,background=fancyframe] \starttext \framed [rulethickness=4pt,framecolor=MyFrameColor,height=8cm,width=8cm]{} \localframed[fancy] [height=8cm,width=8cm]{} \stoptext --------------010105050404070807040402 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ 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 ___________________________________________________________________________________ --------------010105050404070807040402--