From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/31357 Path: news.gmane.org!not-for-mail From: Aditya Mahajan Newsgroups: gmane.comp.tex.context Subject: Re: Make page number appear on top of image Date: Fri, 13 Oct 2006 01:01:09 -0400 (EDT) Message-ID: References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1160715711 31864 80.91.229.2 (13 Oct 2006 05:01:51 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Fri, 13 Oct 2006 05:01:51 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Fri Oct 13 07:01:42 2006 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 ciao.gmane.org with esmtp (Exim 4.43) id 1GYFAo-0006ac-Ar for gctc-ntg-context-518@m.gmane.org; Fri, 13 Oct 2006 07:01:30 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 1E48E1FD5E; Fri, 13 Oct 2006 07:01:29 +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 09977-02-3; Fri, 13 Oct 2006 07:01:19 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 28A6E1FE1E; Fri, 13 Oct 2006 07:01:19 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 290B41FD5E for ; Fri, 13 Oct 2006 07:01:14 +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 09977-02-2 for ; Fri, 13 Oct 2006 07:01:11 +0200 (CEST) Original-Received: from hellskitchen.mr.itd.umich.edu (smtp.mail.umich.edu [141.211.14.82]) by ronja.ntg.nl (Postfix) with SMTP id D10FB1FD54 for ; Fri, 13 Oct 2006 07:01:10 +0200 (CEST) Original-Received: FROM aditya.annarb01.mi.comcast.net (c-68-40-50-205.hsd1.mi.comcast.net [68.40.50.205]) BY hellskitchen.mr.itd.umich.edu ID 452F1D94.BFBCD.19474 ; 13 Oct 2006 01:01:09 -0400 Original-To: mailing list for ConTeXt users In-Reply-To: X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.7 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:31357 Archived-At: On Thu, 12 Oct 2006, Aditya Mahajan wrote: > On Wed, 11 Oct 2006, Aditya Mahajan wrote: > >> Hi, >> I want to combine some papers into a single pdf file "with page >> numbers". I am including the papers using >> >> \copypages[filename] >> >> However, the pagenumber is not printed when the paper is a scanned >> copy. I guess this is because the page number is printed and then the >> scanned image is printed on top of it, thereby hiding the page number. >> >> How can I force the page number to appear on top? > > I tried layer, and it almost works. How do I get the layer to be > evaluated at each page. I get pagenumber=1 on all pages. > > \definelayer > [pagenumber] > [width=\paperwidth,height=\paperheight,state=continue] > > \setupbackgrounds[page][background={foreground,pagenumber}] > > \setlayer[pagenumber] > [corner={right,bottom},location={left,top},x=1cm,y=1cm] > {\tfb \getnumber[page]} > > > with layer state=start I get the page number on only the first page. > With state=repeat|continue I always get 1. What should I use so that > the layer is evaluated again on each page? This is what I ended up doing \startsetups pagenumber \setlayer[pagenumber]{\tfb \getnumber[page]} \stopsetups \setupfootertexts[\setups{pagenumber}] This makes sure that the layer is re-evaluated on each page. This works fine but is there a better way to do this? If not, how about adding something like repeat=page so that the layer is evaluated on each page? Aditya