Changes

Jump to navigation Jump to search
209 bytes added ,  20:11, 8 June 2020
m
no edit summary
< [[Structurals]] | [[Bibliography]] > ==General Use==
If you want to refer to any text element, you must first define the target's reference label. All titling commands and a lot of others take one as optional parameter, e.g.
<texcode>
Starting with ConTeXt 2012.06.22, there is a third command: {{cmd|contentreference|[reference][framedsettings]{text}}} which wraps the <code>text</code> argument inside a {{cmd|framed}}. The main difference with {{cmd|textreference}} where the <code>text</code> contains a {{cmd|framed}} itself is that, when interaction is enabled, {{cmd|contentreference}} places the top left of the target area at the top left of the framed box whereas {{cmd|textreference}} uses its baseline.
== showreferences == You can see [[\showreferences]], when writing a long document with many cross references, to visualize the names given to various nodes. ==Example=== 
<texcode>
\chapter[preface]{Dear Reader}
</context>
== Different layouts for different kinds of references ==
If you want less typing to get special formatting for the references to sections, equations, ... here's Aditya's recipe to do it.
==Adjusting the level of referenced prefixes==
When the default chapter and section prefixes are used, the chapters are
incorporated to adjust the prefixes displayed by the referencing commands.
===Example===
Given that {{cmd|start}}/{{cmd|stopchapter}} output <code>Romannumerals</code> prefixes (<tt>I,
==Adjusting the separator in between the referenced prefixes==
To adjust the separator between the different structure
{{cmd|definestructureseparatorset}} is used.
===Example===
To change the separator between chapter and section from a dot to a hyphen use
</texcode>
==Putting a separator in the heading but not the reference==
Sometimes you want to have a separator in the heading but not the reference. For example, you want section heading to look like "3. This is a new section" (with a dot after the section number), but references to the section should not have the dot (they should be like "In section 3 we found..."). Wolfgang Schuster gave a solution (for MkIV) [http://www.ntg.nl/pipermail/ntg-context/2013/072650.html on the list]:
</texcode>
==References to an external file==
You can refer to referenced elements in an external file. MkIV requires for this the presence of the '''tuc-file''' of the referenced file. ConTeXt will catch the information to be included from this file.
===Example===
External files: hasseltbook.tex/pdf/'''tuc'''
<texcode>\command[symbolic-name::reference]</texcode>
==Related Modules==
* [[Cross Referencing]]: Cross references in a (academic) text are either internal (linking to an other point inside the same document) or external (linking to a entity of the bibliography that points to a different document).
* [[Paragraph Referencing]]: The pararef module understands a paragraph as a full closed block of one thought.
 
=Related pages=
 
* How to access the [[Last Head Number]] in a document
 
{{todo|Describe what the arguments of the commands do and how the commands work}}
{{Getting started navbox}}[[Category:Basics]][[Category:Interaction]][[Category:PDF]]

Navigation menu