ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* marking, headers and 2 columns
@ 2004-04-20 10:42 Tobias Hilbricht
  2004-04-28 18:14 ` Hans Hagen
  0 siblings, 1 reply; 2+ messages in thread
From: Tobias Hilbricht @ 2004-04-20 10:42 UTC (permalink / raw)


Dear readers of this list,
I would like to typeset a bible-text with ConTeXt. The header should
print the first  and the last verse on that particular page. I used the
commands \marking to mark the verses and \getmarking to setup the
headers as shown in the excerpt below. This works correctly with a
single column layout, but not in a two column layout. The last verse
printed in the headers is not the correct one, the first or the second
on the following page is given.
Is there a work around for this problem? Many thanks in advance for
helpful hints

Yours sincerely

Tobias Hilbricht

----------------

% Kopie von nova-vulgata_vt_genesis.html
% zur Weiterbearbeitung mit ConTeXt

\mainlanguage[la]
\language[la]
\setupencoding[default=ec]
\usetypescript[berry][ec]
\setupheadertexts[{\getmarking[vers][first]} --
{\getmarking[vers][last]}][1. Mose]

\definemarking[vers][]

\setupcolumns[2]
\setuppagenumbering[location={footer,right}]

\setupheadertexts[{\getmarking[vers][first]} --
{\getmarking[vers][last]}][Liber Genesis]

\starttext
\startcolumns

LIBER GENESIS

1
\marking[vers]{1, 1}     1 In principio creavit Deus caelum et terram. 
\marking[vers]{1, 2}     2 Terra autem erat inanis et vacua, et tenebrae
super faciem abyssi, et spiritus Dei ferebatur super aquas.
\marking[vers]{1, 3}     3 Dixitque Deus: "Fiat lux". Et facta est lux.
.
... many more verses (12 pages)
.
\stopcolumns
\stoptext

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

* Re: marking, headers and 2 columns
  2004-04-20 10:42 marking, headers and 2 columns Tobias Hilbricht
@ 2004-04-28 18:14 ` Hans Hagen
  0 siblings, 0 replies; 2+ messages in thread
From: Hans Hagen @ 2004-04-28 18:14 UTC (permalink / raw)


At 12:42 20/04/2004, you wrote:
>Dear readers of this list,
>I would like to typeset a bible-text with ConTeXt. The header should
>print the first  and the last verse on that particular page. I used the
>commands \marking to mark the verses and \getmarking to setup the
>headers as shown in the excerpt below. This works correctly with a
>single column layout, but not in a two column layout. The last verse
>printed in the headers is not the correct one, the first or the second
>on the following page is given.
>Is there a work around for this problem? Many thanks in advance for
>helpful hints

i knew it was coming one day ....

add this to cont-new.tex:

\unprotect
     \letvalue{\??mk\??mk\v!kolom:\v!eerste }\getsplitfirstmark
     \letvalue{\??mk\??mk\v!kolom:\v!laatste}\getsplitbottommark
\protect

then this should work (unbalanced only,  and not yet in columnsets)

\definemarking[vers][]

\setupheadertexts[{\getmarking[vers][first] -- \getmarking[vers][column:last]}]

\starttext

\startcolumns[n=2,balance=no]

\dorecurse{10}{\expanded{\marking[vers]{\recurselevel}} 
\recurselevel:\dorecurse{4}{\input ward } \endgraf}

\stopcolumns

\stoptext

The following definition is nicer:

\setupheadertexts
   [\doiftext{\getmarking[vers][first]}
      {\doiftextelse{\getmarking[vers][column:last]}
         {\getmarking[vers][first] -- \getmarking[vers][column:last]}
         {\getmarking[vers][first]}}]

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

end of thread, other threads:[~2004-04-28 18:14 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2004-04-20 10:42 marking, headers and 2 columns Tobias Hilbricht
2004-04-28 18:14 ` Hans Hagen

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