Changes

Jump to navigation Jump to search
1,938 bytes added ,  11:17, 14 October 2011
Two short examples, how \setupreferencestructureprefix and definestructureseparatorset can be used. Unfortunately without any syntax descriptions or explanations
{{todo|complete example would be better}}
 
 
==Adjusting the level of referenced prefixes==
 
When the default chapter and section prefixes are used, the chapters are
prefixed by a number, so are the sections. When referring to a section using
the command <cmd>in{section}[sec:foo]</cmd> the chapter number is prefixed
following by a dot and the according section number.
 
However, some styles do not show the chapter prefix while displaying the
sections. In this case the referencing commands, like <cmd>in</cmd> just output the
section number, which is of course ambiguous.
 
To fix this problem, the command <cmd>setupreferencestructureprefix</cmd> can be
incorporated to adjust the prefixes displayed by the referencing commands.
 
===Example===
 
Given that <cmd>start/stopchapter</cmd> output <tt>Romannumerals</tt> prefixes (<tt>I,
II, III, …</tt>) and <cmd>start/stopsection</cmd> output <tt>Character</tt> prefixes (<tt>A,B, C, …</tt>), the following commands give the results provided in the comments.
 
<texcode>
\setupreferencestructureprefix [default] [prefixsegments=2:2] % nothing
\setupreferencestructureprefix [default] [prefixsegments=2:3] % I
\setupreferencestructureprefix [default] [prefixsegments=2:4] % I.A
 
\setupreferencestructureprefix [default] [prefixsegments=3:4] % I.A
\setupreferencestructureprefix [default] [prefixsegments=4:4] % A
\setupreferencestructureprefix [default] [prefixsegments=5:4] % nothing
</texcode>
 
 
==Adjusting the separator in between the referenced prefixes==
 
To adjust the separator between the different structure
levels in the referencing commands, like <cmd>in</cmd>, the command
<cmd>definestructureseparatorset</cmd> is used.
 
===Example===
 
To change the separator between chapter and section from a dot to a hyphen use
<cmd>definestructureseparatorset</cmd> as follows.
 
<texcode>
\definestructureseparatorset [default] [,,-]
</texcode>
 
{{todo|Describe what the arguments of the commands do and how the commands work}}
69

edits

Navigation menu