From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/82267 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: METAFUN+CONTEXT+CUSTOMIZE Date: Thu, 2 May 2013 23:40:34 +0200 Message-ID: <24E78FA6-F7E2-46EB-A8DD-C215CE464D8C@gmail.com> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Mac OS X Mail 6.3 \(1503\)) Content-Type: multipart/mixed; boundary="===============1513740027==" X-Trace: ger.gmane.org 1367530853 23411 80.91.229.3 (2 May 2013 21:40:53 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 2 May 2013 21:40:53 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Thu May 02 23:40:54 2013 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UY1FF-0007XT-K7 for gctc-ntg-context-518@m.gmane.org; Thu, 02 May 2013 23:40:53 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id AB99A101EB; Thu, 2 May 2013 23:40:52 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 1wW4vJGM6bAV; Thu, 2 May 2013 23:40:50 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 750E9101E5; Thu, 2 May 2013 23:40:50 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 8C2A5101E5 for ; Thu, 2 May 2013 23:40:49 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id ahCXJ3+pI5CW for ; Thu, 2 May 2013 23:40:48 +0200 (CEST) Original-Received: from filter3-utr.mf.surf.net (filter3-utr.mf.surf.net [195.169.124.154]) by balder.ntg.nl (Postfix) with ESMTP id 70850101E4 for ; Thu, 2 May 2013 23:40:38 +0200 (CEST) Original-Received: from mail-ee0-f50.google.com (mail-ee0-f50.google.com [74.125.83.50]) by filter3-utr.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id r42LebQ1021857 for ; Thu, 2 May 2013 23:40:37 +0200 Original-Received: by mail-ee0-f50.google.com with SMTP id e50so512279eek.9 for ; Thu, 02 May 2013 14:40:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=x-received:from:content-type:message-id:mime-version:subject:date :references:to:in-reply-to:x-mailer; bh=9Ufph7OOQlv5774wERFaWrDQRN/R8h+zp6W6DbfmUhk=; b=B0sZHo0grU8i8XdyVxtHIYBS7Q3bCVEljjSdCBkLmUBnT3/HWEzWHqqgQsNMXkQpPr bemAYrDzf73niz9w6rL6zHwEDYwAHFs/MKKRfSNJhmeM7DNWoKCigid9dEfoQR522Mu0 BXkma2eoNWq4Rwt+uegwmRmn99Al/0WV1NkWL5XtuE5sOjRA2ACoWdeg9aaFi6zuWkxu RvcZWSwEtvqq+EX110kfYZmXG7YPvTD/7FgyF1dd9PKIiqcJFKuxGN720TW6OiU23ExC eOeqDQsYArgNc4EvBdNE1wva9qAqjKnM/ZYxxqFKKyfBbKA+17h713C48Qsie/be11ii PYBw== X-Received: by 10.15.31.197 with SMTP id y45mr24129786eeu.18.1367530837210; Thu, 02 May 2013 14:40:37 -0700 (PDT) Original-Received: from keima.localdomain (nrbg-4dbf8b3e.pool.mediaWays.net. [77.191.139.62]) by mx.google.com with ESMTPSA id k43sm12162594een.2.2013.05.02.14.40.36 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 02 May 2013 14:40:36 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.1503) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=74.125.83.50; country=US; region=CA; city=Mountain View; postalcode=94043; latitude=37.4192; longitude=-122.0574; metrocode=807; areacode=650; http://maps.google.com/maps?q=37.4192,-122.0574&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 08Jv9EBWj - e342c8dc2d8c - 20130502 (trained as not-spam) X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.154 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.14 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-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:82267 Archived-At: --===============1513740027== Content-Type: multipart/alternative; boundary="Apple-Mail=_C1AD9518-D291-47B5-9E5C-1219D43CD26D" --Apple-Mail=_C1AD9518-D291-47B5-9E5C-1219D43CD26D Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=utf-8 Am 02.05.2013 um 23:31 schrieb MANUEL GONZALEZ SUAREZ = : >=20 > Hi everyone. >=20 > I would like to pose the following question: I would like to know how = I can customize the page number using an embedded graphic made = =E2=80=8B=E2=80=8Bwith METAFUN. I mean, I wish someone would send me a = simple example to do that, for example, a page number or headers = (chapter, section, etc..) may appear with a color background or = something else. The METAFUN manual provides, for example, the page = number within an ellipse, and the sections are underlined in orange. >=20 > Thank you all for your patience and sorry for my poor English and my = poor knowledge of ConTeXt, but I'm studying hard reference manuals = ConTeXt and hope to go slowly improving, although I am not expert in = computer programming languages =E2=80=8B=E2=80=8Bor even less in = mathematics. >=20 > Thanks very much. >=20 These are only simple styles but the show how you can customize the = heading and pagenumber. \define[2]\ChapterCommand {\startframed[frame=3Doff,bottomframe=3Don,framecolor=3Dorange,width=3Df= it] #1\hspace[medium]#2 \stopframed} \setuphead[chapter][command=3D\ChapterCommand] \startuseMPgraphic{pagenumber} draw fullcircle xyscaled(OverlayWidth,OverlayHeight) withcolor = \MPcolor{blue} ; \stopuseMPgraphic \defineoverlay[pagenumber][\useMPgraphic{pagenumber}] \define[1]\PagenumberCommand {\framed[frame=3Doff,background=3Dpagenumber]{#1}} \setuppagenumbering[command=3D\PagenumberCommand] \starttext \chapter{This is a chapter} \stoptext Wolfgang --Apple-Mail=_C1AD9518-D291-47B5-9E5C-1219D43CD26D Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=utf-8 gonzalezsmanuel@uniovi.es>= ;:

Hi everyone.

I would like to pose the following question: I would like to know how I can = customize the page number using an embedded graphic made =E2=80=8B=E2=80=8Bwith METAFUN. = I mean, I wish someone would send me a simple example to do that, for example, a = page number or headers (chapter, section, etc..)  may appear with a color background or something else. The METAFUN manual provides, for example, the page = number within an ellipse, and the sections are underlined in = orange.

Thank you all for your patience and sorry for my poor English and my poor = knowledge of ConTeXt, but I'm studying hard reference manuals ConTeXt and hope to go = slowly improving, although I am not expert in computer programming languages = =E2=80=8B=E2=80=8Bor even less = in mathematics.

Thanks very much.

These are only = simple styles but the show how you can customize the heading and = pagenumber.

\define[2]\ChapterCommand
<= div>  = {\startframed[frame=3Doff,bottomframe=3Don,framecolor=3Dorange,width=3Dfit= ]
    #1\hspace[medium]#2
    = \stopframed}

\setuphead[chapter][command=3D\Chapt= erCommand]

\startuseMPgraphic{pagenumber}
  draw fullcircle xyscaled(OverlayWidth,OverlayHeight) withcolor = \MPcolor{blue} = ;
\stopuseMPgraphic

\defineoverlay[page= number][\useMPgraphic{pagenumber}]

\define[1]\Pag= enumberCommand
  = {\framed[frame=3Doff,background=3Dpagenumber]{#1}}

\setuppagenumbering[command=3D\PagenumberCommand]

\starttext
\chapter{This is a = chapter}
\stoptext

Wolfgang
=
= --Apple-Mail=_C1AD9518-D291-47B5-9E5C-1219D43CD26D-- --===============1513740027== 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 : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ --===============1513740027==--