29.05.2014 Views

ConTEXt the manual Hans Hagen - Pragma ADE

ConTEXt the manual Hans Hagen - Pragma ADE

ConTEXt the manual Hans Hagen - Pragma ADE

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Documents 23<br />

content<br />

index<br />

commands<br />

macros<br />

\startcomponent second<br />

\part{Two}<br />

\completecontent<br />

\chapter{Alfa}<br />

..... text .....<br />

\chapter{Beta}<br />

file: second.tex<br />

The product contains more than one component. We<br />

could have defined a product for each part and a component<br />

for each chapter.<br />

..... text .....<br />

\completeindex<br />

\stopcomponent<br />

The files first.tex, second.tex and example.tex can be processed separately. As long as<br />

<strong>the</strong>re is one product in this project you can also process project.tex. If you process an<br />

environment <strong>the</strong>re will be no pages of output.<br />

2.4 Directories<br />

Many T E X implementations look for a file in all directories and subdirectories when a requested<br />

file is not in <strong>the</strong> current directory. This is not only time--consuming but may lead to errors<br />

when <strong>the</strong> wrong file (a file with <strong>the</strong> same name) is loaded.<br />

For this reason ConT E Xt works somewhat differently. A file that is not available on <strong>the</strong> working<br />

directory is searched for on <strong>the</strong> parent directories. This means that environments can be placed<br />

in directories that are parents to <strong>the</strong> products that use <strong>the</strong>m. For example:<br />

2.1 Introduction 17<br />

2.2 Start and stop 17<br />

2.3 Structure 18<br />

2.4 Directories 23<br />

2.5 Versions 23<br />

2.6 Modes 24<br />

/texfiles/course/layout.tex<br />

/texfiles/course/teacher/<strong>manual</strong>.tex<br />

/texfiles/course/student/learnmat.tex<br />

/texfiles/course/o<strong>the</strong>rdoc/sheets.tex<br />

The last three files (in different subdirectories) all use <strong>the</strong> same environment layout.tex. So,<br />

instead of putting all files into one directory, one can organize <strong>the</strong>m in subdirectories. When<br />

a project is properly set up, that is, as long as <strong>the</strong> project file and specific environments can<br />

be found, one can process components and products independently.<br />

2.5 Versions<br />

During <strong>the</strong> process of document production it is useful to generate a provisional version. This<br />

version shows <strong>the</strong> references and <strong>the</strong> typesetting failures. The provisional version is produced<br />

when you type:<br />

search go back exit<br />

Directories — Versions 2

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!