[NTG-context] Newbie questions

Thomas Moore tmoore at pomona.edu
Thu Jun 29 16:57:50 CEST 2006

On Jun 28, 2006, at 6:12 PM, Aditya Mahajan wrote:

>> Dear ConTeXt gurus:
> I am not a context guru, but will still give it a shot ;)

Thanks for your help!
>> OK, I have gotten some off-list help from Mojca, who has answered
>> most of my questions and helped me polish the two page version of my
>> code (thanks, Mojca!). I have included what he helped me work out
>> below. There is one remaining problem. The first page is correct, but
>> very subsequent page has a correct-looking header and another
>> superimposed. The second superimposed header is not wide enough and
>> has the wrong page number (the number of the previous page), though
>> the page number is on the correct side. It is as if the page output
>> command from TeX is issuing the \setups command *twice*, once before
>> fully updating variables like \rightmarginwidth and the page number,
>> and once after setups have been done correctly. Is this a bug, or am
>> I doing something stupid?
>> Thanks for any insight, Tom
> I am not sure what about the exact layout you are trying to achieve.
> Does this give you what you want.
> \setuppapersize[letter]
> \setuppagenumbering
>    [alternative=doublesided,location=]
> \setuplayout
>         [backspace=1.0in,
>         topspace=0.5in,
>         width=4.5in,
>         height=9.5in,
>         rightmargin=2.35in,
>         rightmargindistance=0.15in,
>         leftmargin=0in,
>         leftmargindistance=0in,
>         header=\normallineheight,
>         headerdistance=\dimexpr0.5in-\normallineheight,
>         footer=0in]
> \setupheadertexts[chapter][pagenumber][pagenumber][chapter]
> \setupbackgrounds[header][text][bottomframe=on,rulethickness=1pt]
>   \starttext
>   \chapter{Test}
>   This is a test of some math stuff. $0 = g_{\mu\nu}dx^\nu dx^\nu$.
>   \dorecurse{10}{\input knuth}
>   \showlayout
>   \stoptext

Sorry, no. The additional feature that I need is to be able to extend  
the horizontal line over the margin region as well as the text  
region, and put the page number (outer-justified) at the outer edge  
of the margin region. The code that I attached to the previous  
message does that, but suffers from the superimposed headers problem.  
But I appreciate your effort!

Best wishes,  Tom

More information about the ntg-context mailing list