Re: [NTG-context] reference error
\starttext \startchapter [ title=Vorwort, reference=chap:vorwort with space at the end ] \stopchapter
\startchapter [ title=Vorwort, reference={chap:vorwort2 with space at the end} ] \stopchapter
\startchapter [ title=Vorwort, reference={chap:vorwort3 with space at the end }] \stopchapter
\startchapter [ title=Vorwort, reference=chap:vorwort without space at the end] \stopchapter
\startchapter [ title=Vorwort, reference={chap:vorwort2 without space at the end}] \stopchapter
\startchapter \ConTeXt\ does not support space at the end of references: Siehe \in{Kapitel}[chap:vorwort with space at the end ], \in{Kapitel}[chap:vorwort2 with space at the end ], \in{Kapitel}[chap:vorwort3 with space at the end ], \in{Kapitel}[chap:vorwort without space at the end] and \in{Kapitel}[chap:vorwort2 without space at the end] \stopchapter \stoptext
Only the last two are working! Not the second!!! Not very intuitive at all. Wolfgang
On Sun, Nov 03 2013, Wolfgang Werners-Lucchini wrote:
\in{Kapitel}[chap:vorwort with space at the end ], \in{Kapitel}[chap:vorwort2 with space at the end ], \in{Kapitel}[chap:vorwort3 with space at the end ], \in{Kapitel}[chap:vorwort without space at the end] and \in{Kapitel}[chap:vorwort2 without space at the end]
Only the last two are working! Not the second!!! Not very intuitive at all.
The first 3 are almost the same. If you really want a space at the end, then you could add a feature request to http://tracker.luatex.org/ If you just want to write "\command[ key=value ]", that does not work. ConTeXt needs to know where the value ends: at a "," or a "]". This could be a possibility for you: "\command[ key=value, ]". -- Peter
Am 04.11.2013 um 09:43 schrieb Peter Münster
On Sun, Nov 03 2013, Wolfgang Werners-Lucchini wrote:
\in{Kapitel}[chap:vorwort with space at the end ], \in{Kapitel}[chap:vorwort2 with space at the end ], \in{Kapitel}[chap:vorwort3 with space at the end ], \in{Kapitel}[chap:vorwort without space at the end] and \in{Kapitel}[chap:vorwort2 without space at the end]
Only the last two are working! Not the second!!! Not very intuitive at all.
The first 3 are almost the same. If you really want a space at the end, then you could add a feature request to http://tracker.luatex.org/
I’n not sure is going to change this because the reference parser removes trailing/leading spaces in references. One shouldn’t forgot the reference commands accept more than simple references to a section, float etc. but also hyperlinks to other pages (first, last etc.) or external documents. BTW: The code which removes the space in reference is on strc-rsc.lua Wolfgang
On 11/4/2013 10:00 AM, Wolfgang Schuster wrote:
Am 04.11.2013 um 09:43 schrieb Peter Münster
: On Sun, Nov 03 2013, Wolfgang Werners-Lucchini wrote:
\in{Kapitel}[chap:vorwort with space at the end ], \in{Kapitel}[chap:vorwort2 with space at the end ], \in{Kapitel}[chap:vorwort3 with space at the end ], \in{Kapitel}[chap:vorwort without space at the end] and \in{Kapitel}[chap:vorwort2 without space at the end]
Only the last two are working! Not the second!!! Not very intuitive at all.
The first 3 are almost the same. If you really want a space at the end, then you could add a feature request to http://tracker.luatex.org/
I’n not sure is going to change this because the reference parser removes trailing/leading spaces in references. One shouldn’t forgot the reference commands accept more than simple references to a section, float etc. but also hyperlinks to other pages (first, last etc.) or external documents.
BTW: The code which removes the space in reference is on strc-rsc.lua
Also, one can pass multiple references as in: \startchapter[reference={foo,bar},...] Anyhow, as an experiment I've added a space stripper to the 'definition' part of references \starttext \startsection [title=Test 1, reference=ref 1] \stopsection \startsection [title=Test 2, reference={ref 2}] \stopsection \startsection [title=Test 3, reference= {ref 3}] \stopsection \startsection [title=Test 4, reference={ref 4} ] \stopsection \startsection [title=Test 5, reference= {ref 5} ] \stopsection \startsection [title=Test 6, reference={ ref 6 , ref 7 }] \stopsection \dorecurse{7}{ \in{ref}[ref #1] \in{ref}[ ref #1] \in{ref}[ref #1 ] \in{ref}[ ref #1 ] \par } \stoptext This all works ok but someone needs to document it at the wiki. Of course one can come up with yet another 'wanted tolerance' but we shouldn't become to fuzzy. Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------
participants (4)
-
Hans Hagen
-
Peter Münster
-
Wolfgang Schuster
-
Wolfgang Werners-Lucchini