Changes

Jump to navigation Jump to search
3,815 bytes added ,  22:06, 29 July 2021
conflict with setupinteraction
|attributes=
}}
 
== [[Help:Reference|Syntax]] (autogenerated) ==
<syntax>setupregister</syntax>
== [[Help:Reference|Syntax]] ==
</tr>
<tr valign="top" class="third">
<td class="cmd">[[Command/keyword:check|check]]</td>
<td>[[Command/value:yes|yes]] [[Command/value:no|no]] </td>
</tr> <tr valign="top" class="third">
<td class="cmd">[[Command/keyword:sectionnumber|sectionnumber]]</td>
<td>[[Command/value:yes|yes]] [[Command/value:no|no]] </td>
<tr valign="top" class="third">
<td class="cmd">[[Command/keyword:compress|compress]]</td>
<td>[[Command/value:yes|yes]] [[Command/value:no|no]] [[Command/value:text|text]]</td> </tr> <tr valign="top" class="third"> <td class="cmd">[[Command/keyword:language|language]]</td> <td>[[Command/value:language|language code]]</td> </tr> <tr valign="top" class="third"> <td class="cmd">[[Command/keyword:method|method]]</td> <td>[[Command/value:default|default]] [[Command/value:before|before]] [[Command/value:after|after]] [[Command/value:first|first]] [[Command/value:last|last]]</td> </tr> <tr valign="top" class="third"> <td class="cmd">[[Command/keyword:pageleft|pageleft]]</td> <td>[[Command/value:command|command]]</td> </tr> <tr valign="top" class="third"> <td class="cmd">[[Command/keyword:pageright|pageright]]</td> <td>[[Command/value:command|command]]</td>
</tr>
</table>
== Description ==
== Description == The options are as follows (beware, some options can be in conflict with {{cmd|setupinteraction}} and changing parameters has no impact, e.g. <tt>pagestyle</tt>):
The options are <table cellspacing="4" cellpadding="2"><tr> <th>Option</th> <th>Description</th></tr><tr> <td>n</td> <td>number of columns</td></tr><tr> <td>balance</td> <td>balance columns?</td></tr><tr> <td>align</td> <td>balance related (it’s difficult; try which combination suits you)</td></tr><tr> <td>style</td> <td>style of the indicator letters</td></tr><tr> <td>pagestyle</td> <td>style of page number</td></tr><tr> <td>textstyle</td> <td>style of index word</td></tr><tr> <td>indicator</td> <td>create letter sections?</td></tr><tr> <td>coupling</td> <td>special feature for screen documents (no effect in MkIV?)</td></tr><tr> <td>check</td> <td>set {{cmd|seeindex}} entry as followsentered without verifying. Default no.</td></tr><tr> <td>(section)number</td> <td>print part/... numbers?</td></tr><tr> <td>criterium</td> <td>for part/chapter/section registers</td></tr><tr> <td>distance</td> <td>between text and pagenumber as well as indentation of nested entries</td></tr><tr> <td>symbol</td> <td>for pagenumber (a=a,b,c; n=1,2,3; 1=dots; 2=blocks)</td></tr><tr> <td>interaction</td> <td>which part should be clickable?</td></tr><tr> <td>expansion</td> <td>When the entry is a command or XML element, expansion=yes forces the expansion before writing to the TUC file (register). Otherwise non-expanded form will be written (command or refference to the XML element).</td></tr><tr> <td>referencing</td> <td>create references for letter sections (like "index:a")?</td></tr><tr> <td>textcommand</td> <td>custom command for index word</td></tr><tr> <td>pagecommand</td> <td>custom command for page number</td></tr><tr> <td>location</td> <td>?</td></tr><tr> <td>compress</td> <td>collapse page numbers (i.e. make “10–13” from “10,11,12,13”); “<tt>text</tt>” (new in April 2019) makes “10ff.”. You can configure the latter via {{cmd|setuplabeltext}}<tt>[en][following:singular=f.,following:plural=ff.]</tt></td></tr><tr> <td>maxwidth</td> <td>Set the maximum length for the text of the index entry in the registerlist (the command uses {{cmd|limitatetext}} to do this)</td></tr><tr> <td>unknownreference</td> <td>insert a horizontal space before and after the reference in the text if you use interactive mode to move from one entry in the text to next or previous one and there is no previous or next reference.</td></tr><tr> <td>alternative</td> <td>?</td></tr><tr> <td>language</td> <td>language code like in {{cmd|language}}, influences sorting; see definitions in {{src|sort-lan.mkiv}}</td></tr><tr> <td>method</td> <td>sets up the sorter used for {{cmd|placeregister}}, explained at [[Command/keyword:method]]</td></tr><tr> <td>pageleft</td> <td>custom command before the first page number</td></tr><tr> <td>pageright</td> <td>custom command after the last page number</td></tr></table>
* n: number of columns* balance: balance columns?* align: ?* style: overall style(?)* pagestyle: style of page number* textstyle: style of index word* indicator: create letter sections?* coupling: special feature for screen documents* (section)number: print part/... numbers?* criterium: for part/chapter/section registers* distance: between text and pagenumber* symbol: for pagenumber (a=a,b,c; n=1,2Some options don’t seem to have any effect,3; 1=dots; 2=blocks)* interaction: which part should be clickable?* expansion: ?* referencing: create references for letter sections (like "index:a")?* textcommand: custom command for index word* pagecommand: custom command for page number* location: ?* compress: collapse page numbers* maxwidth: Set the maximum length for the text of the index entry in the registerlist (the command uses {{cmd|limitatetext}} to do this)* unknownreference: insert a horizontal space before and after the reference in the text if you use interactive mode to move from one entry at least in the text to next or previous one and there is no previous or next referenceMkIV.* alternative:
== Example ==
 
Here is an example for MkII:
<context source="yes" text="yields">
I found it safer to put \register command after punctuation e.g.: Mamut.\nickname{Mamut} [P.K.]
 
For the MkIV version of setting the pagestyle, and more, see the material on {{cmd|defineprocessor}} that is on [[Registers#Processors|this page]].
 
== pageleft and pageright ==
 
They were introduced in ConTeXt MkIV version 1.02 (2018.05.12 00:07).
 
You can use them, for example, to move the page numbers to the right, with:
 
<pre>
\setupregister[index][pageleft=\wordright\bgroup,pageright=\egroup]
</pre>
 
See [http://www.mail-archive.com/ntg-context@ntg.nl/msg87812.html this thread]
on the mailing list.
 
In MkXL (lmtx) one would rather use:
 
<pre>
\setupregister[index]
[pageleft=\hfilll,
pageright=\frozen\parfillleftskip 0pt plus 1fill\frozen\parfillrightskip 0pt\par]
</pre>
 
== See also ==
<!-- something like * {{cmd|gotoindex}}* {{gen|register}} -->
== Help from ConTeXt-Mailinglist/Forum ==
138

edits

Navigation menu