For collapsing or expanding page numbers in indexes / registers, you can use \defineregister[name][compress=yes|no], e.g.


   \photographer{Yousuf Karsh} \page}


which will result in an index that subsumes the page references to "1-4".

(Example taken from http://wiki.contextgarden.net/Command/defineregister.)


The compress parameter works fine, but it also collapses when we have exactly two sequential page numbers, e.g. "1-2"

Unfortunately, this is very uncommon in German. Instead of "1-2" you would write "1f." when an entry refers to exactly two sequential pages.


Is it possible to subsume page references that encompass exactly two sequential pages to e.g. "1f." while collapsing references that refer to more than two pages to e.g. "1-3"? If so, how would you do it?


You can hack into the display of the pagerange in ConTeXt.





\dorecurse{1}{Foo\photographer{Foo Bar} \page}
\dorecurse{2}{Foo\photographer{John Doe} \page}
\dorecurse{4}{Foo\photographer{Yousuf Karsh} \page}


enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.