ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Hans Hagen <pragma@wxs.nl>
Subject: Re: How to implement a changing navigation bar?
Date: Mon, 16 Aug 2004 23:33:54 +0200	[thread overview]
Message-ID: <41212842.9020800@wxs.nl> (raw)
In-Reply-To: <4120DCF2.7010808@gmx.de>

Stefan Wachter wrote:

> Hi all,
>
> I use an overlay to implement a navigation bar in the left margin of a 
> document. It seems to me that the processing of the overlay is done 
> only once and not for every page again. In addition, the \lastpage is 
> not available.

page, paper and text backgrounda are calculated each page, unless you 
say \setupbackgrounds[state=repeat], in which case all are recalculated; 
if you put something in a layer it happens directly (but the layer may 
be flushed later)

> Does anyone know a solution? Maybe headers/footers are a solution. But 
> how is absolute positioning accomplished with them?
>
you can put a layer in the background of the header area and that do 
something:

\startsetups whatever

  \setlayer[thatlayer][....positioning...]{\the\pageno}

\stopsetups

\setupheadertexts[\setups{whatever}]

> PS: Here is my current implementation:
>
> \definelayer[navbar]
> \setupbackgrounds[text][leftmargin][background=navbar]
> \setlayer[navbar][x=0cm,y=10cm]{\the\pageno}

lastpage etc only make sense in the output routine (during page building) since one does not know where tex will break the page. 

H 

-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------

  parent reply	other threads:[~2004-08-16 21:33 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-08-16 16:12 Stefan Wachter
2004-08-16 15:58 ` Vit Zyka
2004-08-16 17:40   ` Stefan Wachter
2004-08-16 17:46     ` Vit Zyka
2004-08-17 15:53   ` Hans Hagen
2004-08-16 21:33 ` Hans Hagen [this message]
2004-09-23  9:57   ` problem with goto - was: " Stefan Wachter

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=41212842.9020800@wxs.nl \
    --to=pragma@wxs.nl \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).