[NTG-context] author in ToC and other design complications

jbf roma83537 at gmail.com
Fri Sep 4 12:08:55 CEST 2020


Thanks, and I am sure that this entry into the wiki will be also helpful 
for others. For me it will be step by step, and using your information I 
can now at least get an author's name into the toc! But that's about 
all. Just know that when you say (in the new wiki addition) 'check on 
\rawstructurelistuservariable' that  link simply tells me 'There is 
currently no text in this page'. That leaves someone like me without a 
lot of the long-gained knowledge that others have, quite lost :-)

But I took your example and adjusted it for, say, a chapter which has 
just a title (no subtitle) and an author, and added, below what I 
already have in the preamble:

\define[1]\ChapterTocEntry{%
   \structurelistuservariable{author}\crlf%
   #1\crlf% title
   %\structurelistuservariable{subtitle}}%
}

\setuplist[chapter][
   textcommand=\ChapterTocEntry,
]

So, in other words I swapped the word 'section' in your example with 
'chapter'. That now gives me in the ToC, something like the following:

One   Author name

          Title                        pg no.

Which is pretty much what I am after. Hooray! But how do I get that in 
reverse? And how do I get the word 'chapter' to also appear in front of 
'One'? You see what I mean by needing step-by-step. Maybe there are not 
too many nearly 75+-year-olds still surviving Covid and working with 
ConTeXt! But I don't give up too easily, so let me just get this next 
step right with a bit of help.

Julian

n 4/9/20 5:38 pm, Henning Hraban Ramm wrote:

>
>> Am 04.09.2020 um 06:44 schrieb jbf <roma83537 at gmail.com>:
>>
>>
>> Of course, I would prefer it to say 'Chapter One' not just 'One', so that is a minor problem I still have to resolve. But in fact, the publisher wants something quite different and I really do not know how to go about it. I did look at 'Author in ToC' in the wiki, but that referred me to a somewhat complicated Proceedings style, and given that my Chapters are all set up anyway, I just couldn't follow that. Am hoping there is some other way I can achieve the design that follows:
>>
>> Foreword            Author's name        iii
>>
>> Chapter One       Chapter title
>>
>>                              Author's name       1
>>
>> Chapter Two        1820-1880
>>
>>                              Chapter title
>>
>>                              Author's name       10
> I just replaced the according section https://wiki.contextgarden.net/Table_of_Contents#Author_in_ToC for you.
>
> Hraban
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to the Wiki!
>
> maillist : ntg-context at ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki     : http://contextgarden.net
> ___________________________________________________________________________________


More information about the ntg-context mailing list