Changes

Jump to navigation Jump to search
1,046 bytes added ,  07:42, 3 December 2008
Mari added a section about using multiple layouts so she can find it again easier than by digging it out on the mailing list. The solution given has been tested.
== Keep ==
If you have a certain run of text that you want to keep together, you can test for the number of lines available on the current page with \testpage[n] where n is the number of lines required. If there are not n lines available, a page break will be inserted at the location of the testpage command.
 
 
== Multiple layouts ==
 
If you need to use different layouts in some parts of the document, you can set up a global layout for the overall and then define additional named layouts for the deviating parts. These settings go into the setup area of your document.
 
<texcode>
\setuplayout[key=value,key=value,...] %global layout
\definelayout[wide][key=value,key=value,...] %different layout called 'wide'
\definelayout[short][key=value,key=value,...]%different layout called 'short'
</texcode>
 
That takes care of the global layout. When you want to switch to a different layout, you just call it up in the appropriate place in the document:
 
<texcode>
\setuplayout[wide] % switches to layout called 'wide'
</texcode>
 
'''Note.''' Use reset to revert back to the global layout:
 
<texcode>
\setuplayout[reset] % reverts to the global layout
</texcode>
 
''This text is based on at [http://archive.contextgarden.net/message/20080926.111520.9db86904.en.html a thread on the mailing list], answers and examples are given there by Hans and Wolfgang.''
== Hints ==
102

edits

Navigation menu