ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* [NTG-context] page number
@ 2024-05-26  9:27 Charles Doherty via ntg-context
  2024-05-26 10:30 ` [NTG-context] " Mikael Sundqvist
  2024-05-26 12:07 ` Wolfgang Schuster
  0 siblings, 2 replies; 3+ messages in thread
From: Charles Doherty via ntg-context @ 2024-05-26  9:27 UTC (permalink / raw)
  To: Wolfgang Schuster via ntg-context; +Cc: Charles Doherty

Dear Wolfgang,

I have a book in preparation with running heads.


Pagenumber  marking   |    marking      Pagenumber

The chapter title page has empty headings. 

The publisher would like the page number centered on the Chapter title page. I manage to put it there but I don’t want it to run on the following pages. I have made various attempts but can’t manage it.

I have

\setuplayout[location=doublesided]
\setuppagenumbering[location=,alternative=doublesided]

\setupheadertexts[chapter][][pagenumber]
\setupheadertexts[{\getmarking[chapter]}][pagenumber]

Can anyone show me code to achieve this?

Thanks,
Charlie 



___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

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

* [NTG-context] Re: page number
  2024-05-26  9:27 [NTG-context] page number Charles Doherty via ntg-context
@ 2024-05-26 10:30 ` Mikael Sundqvist
  2024-05-26 12:07 ` Wolfgang Schuster
  1 sibling, 0 replies; 3+ messages in thread
From: Mikael Sundqvist @ 2024-05-26 10:30 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hi Charles,

On Sun, May 26, 2024 at 11:39 AM Charles Doherty via ntg-context
<ntg-context@ntg.nl> wrote:
>
> Dear Wolfgang,
>
> I have a book in preparation with running heads.
>
>
> Pagenumber  marking   |    marking      Pagenumber
>
> The chapter title page has empty headings.
>
> The publisher would like the page number centered on the Chapter title page. I manage to put it there but I don’t want it to run on the following pages. I have made various attempts but can’t manage it.
>
> I have
>
> \setuplayout[location=doublesided]
> \setuppagenumbering[location=,alternative=doublesided]
>
> \setupheadertexts[chapter][][pagenumber]
> \setupheadertexts[{\getmarking[chapter]}][pagenumber]
>
> Can anyone show me code to achieve this?
>
> Thanks,
> Charlie

I notice that you addressed Wolfgang, but you also sent to the list.
One way could be to condition on being on a chapter page:

\setupheadertexts
  [\doifelsefirstsectionpage{chapter}{\userpagenumber}{}]

\setupheadertexts
  [\doifelsefirstsectionpage{chapter}{}{\getmarking[chapter]}]
  [\doifelsefirstsectionpage{chapter}{}{\userpagenumber}]

/Mikael
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

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

* [NTG-context] Re: page number
  2024-05-26  9:27 [NTG-context] page number Charles Doherty via ntg-context
  2024-05-26 10:30 ` [NTG-context] " Mikael Sundqvist
@ 2024-05-26 12:07 ` Wolfgang Schuster
  1 sibling, 0 replies; 3+ messages in thread
From: Wolfgang Schuster @ 2024-05-26 12:07 UTC (permalink / raw)
  To: mailing list for ConTeXt users, Charles Doherty via ntg-context

Charles Doherty via ntg-context schrieb am 26.05.2024 um 11:27:
> Dear Wolfgang,
> 
> I have a book in preparation with running heads.
> 
> 
> Pagenumber  marking   |    marking      Pagenumber
> 
> The chapter title page has empty headings.
> 
> The publisher would like the page number centered on the Chapter title page. I manage to put it there but I don’t want it to run on the following pages. I have made various attempts but can’t manage it.
> 
> I have
> 
> \setuplayout[location=doublesided]
> \setuppagenumbering[location=,alternative=doublesided]
> 
> \setupheadertexts[chapter][][pagenumber]
> \setupheadertexts[{\getmarking[chapter]}][pagenumber]

Please send a complete working example next time.

> Can anyone show me code to achieve this?

1. You use \setupheadertexts to set the header for all pages.

2. You use \definetext to create a custom header for the chapter page 
and apply it with the header-key in \setuphead.

%%%% begin example
\setuppagenumbering
   [location=,
    alternative=doublesided]

\setupheadertexts
   [chapter] [pagenumber]
   [pagenumber] [chapter]

\definetext
   [chapterheader]
   [header]
   [pagenumber]

\setuphead
   [chapter]
   [header=chapterheader]

\starttext
\dorecurse{10}
   {\startchapter[title=Chapter \convertnumber{Word}{#1}]
    \dorecurse{10}{\samplefile{lorem}}
    \stopchapter}

\stoptext
%%%% end example

Wolfgang
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

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

end of thread, other threads:[~2024-05-26 12:09 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-05-26  9:27 [NTG-context] page number Charles Doherty via ntg-context
2024-05-26 10:30 ` [NTG-context] " Mikael Sundqvist
2024-05-26 12:07 ` Wolfgang Schuster

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).