ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Newbie question on \completecontent
@ 2003-08-06 12:27 Gerben Wierda
  2003-08-06 14:52 ` Matthias Weber
  2003-08-06 19:43 ` Hans Hagen
  0 siblings, 2 replies; 3+ messages in thread
From: Gerben Wierda @ 2003-08-06 12:27 UTC (permalink / raw)


Suppose I create this document:

> \starttext
> \completecontent
> \chapter{One}
> \input tufte
> \chapter{Two}
> \input douglas
> \stoptext

I get a document with a content list and two chaqpters. Now I want to 
do the same in a project. I take the example from the manual and do 
this:

> %%
> %% This is the file book.tex
> %%
> \startproduct book
> \project teoade
>
> \startfrontmatter
>  \completecontent
> \stopfrontmatter
>
> \startbodymatter
>  \component chapters/chapter1
>  \component chapters/chapter2
> \stopbodymatter
>
> \startbackmatter
>  \completeindex
> \stopbackmatter
> \stopproduct

I get the chapters allright, but the list of contents and the index are 
empty. Why?

Thanks,

Gerben

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

* Re: Newbie question on \completecontent
  2003-08-06 12:27 Newbie question on \completecontent Gerben Wierda
@ 2003-08-06 14:52 ` Matthias Weber
  2003-08-06 19:43 ` Hans Hagen
  1 sibling, 0 replies; 3+ messages in thread
From: Matthias Weber @ 2003-08-06 14:52 UTC (permalink / raw)


Hello Gerben,

I am a beginner myself, and working on a book project too. Below I send
you my complete directory setup with sample files. I am happy with the 
set-up and
it might also be useful for you.


Matthias

Directory structure:


sas.tex % main project file
layout.tex % main layout file
screenbook/screenbook.tex  % product file


part1/chapter1/chapter1.tex
part1/chapter1/section1/section1.tex



And here the files:

% sas.tex:

\startproject sas

\environment layout

\product screenbook/screenbook

\stopproject

%layout.tex
% contains definitions and 'styles' relevant for all products

\startenvironment layout

\setuppagenumbering[location={footer,middle}]

\setuphead
[chapter]
[numberstyle=bold,
textstyle=cap,
before=\hairline\blank,
after={\nowhitespace\hairline\blank[line]}]


\stopenvironment



% screenbook/screenbook.tex

% contains definitions for the relevant product
% Maybe this can be moved to a secondary environment file,
% I haven't tried that yet.

\startproduct screenbook

\setupcolors[state=start]
\project sas
\setuppapersize[S6][S6]
\startfrontmatter

\starttext
\startstandardmakeup
\midaligned{My Little Book --- Screen Version}
\midaligned{by}
\midaligned{Myself}
\stopstandardmakeup
\stoptext


\completecontent

\stopfrontmatter

\startbodymatter

\component part1/part1
\component part2/part2
\component part3/part3
\component part4/part4
\stopbodymatter

\startbackmatter
\completeindex
\stopbackmatter

\stopproduct



% part1/chapter1/chapter1.tex

\chapter{My first chapter}

\starttext

This is about whatever I have to say.

\input part1/chapter1/section1/section1

\stoptext



% part1/chapter1/section1/section1.tex
% put all helper (images etc) files in this directory, too
% This file contains the actual text and doesn't see the project 
structure
% anymore.

\section{My first section}

blah blah blah

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

* Re: Newbie question on \completecontent
  2003-08-06 12:27 Newbie question on \completecontent Gerben Wierda
  2003-08-06 14:52 ` Matthias Weber
@ 2003-08-06 19:43 ` Hans Hagen
  1 sibling, 0 replies; 3+ messages in thread
From: Hans Hagen @ 2003-08-06 19:43 UTC (permalink / raw)


At 14:27 06/08/2003 +0200, you wrote:
>Suppose I create this document:
>
>>\starttext
>>\completecontent
>>\chapter{One}
>>\input tufte
>>\chapter{Two}
>>\input douglas
>>\stoptext
>
>I get a document with a content list and two chaqpters. Now I want to do 
>the same in a project. I take the example from the manual and do this:
>
>>%%
>>%% This is the file book.tex
>>%%
>>\startproduct book
>>\project teoade
>>
>>\startfrontmatter
>>  \completecontent
>>\stopfrontmatter
>>
>>\startbodymatter
>>  \component chapters/chapter1
>>  \component chapters/chapter2
>>\stopbodymatter
>>
>>\startbackmatter
>>  \completeindex
>>\stopbackmatter
>>\stopproduct
>
>I get the chapters allright, but the list of contents and the index are 
>empty. Why?

because they are produced on a per section basis depending on where you 
call for them (for instance, in a chapter you can say \placelist[section] 
and get a locat toc)

\completecontent[way=bytext]

gives you a document one

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------

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

end of thread, other threads:[~2003-08-06 19:43 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2003-08-06 12:27 Newbie question on \completecontent Gerben Wierda
2003-08-06 14:52 ` Matthias Weber
2003-08-06 19:43 ` 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).