ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Make page number appear on top of image
@ 2006-10-12  0:26 Aditya Mahajan
  2006-10-12 17:29 ` Aditya Mahajan
  0 siblings, 1 reply; 3+ messages in thread
From: Aditya Mahajan @ 2006-10-12  0:26 UTC (permalink / raw)


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?

Thanks,
Aditya

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Make page number appear on top of image
  2006-10-12  0:26 Make page number appear on top of image Aditya Mahajan
@ 2006-10-12 17:29 ` Aditya Mahajan
  2006-10-13  5:01   ` Aditya Mahajan
  0 siblings, 1 reply; 3+ messages in thread
From: Aditya Mahajan @ 2006-10-12 17:29 UTC (permalink / raw)


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?

Aditya

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: Make page number appear on top of image
  2006-10-12 17:29 ` Aditya Mahajan
@ 2006-10-13  5:01   ` Aditya Mahajan
  0 siblings, 0 replies; 3+ messages in thread
From: Aditya Mahajan @ 2006-10-13  5:01 UTC (permalink / raw)


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

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-10-13  5:01 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-10-12  0:26 Make page number appear on top of image Aditya Mahajan
2006-10-12 17:29 ` Aditya Mahajan
2006-10-13  5:01   ` Aditya Mahajan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).