On Sun, 17 Jan 2016 19:27:31 +0100
Wolfgang Schuster
Kate F mailto:kate@elide.org 17. Januar 2016 um 18:53 On 17 January 2016 at 17:00, Wolfgang Schuster
I don't know, actually. In this case these are values which remain constant throughout the document. So all I'm after here is a mechanism for storing variables by name. Is there something more appropriate to use for those kind of variables? You can use the \setvariables command the set the values and access them with \getvariables:
\setvariables [information] [title=Document title, author=Author name]
\setupinteraction [ state=start, title=\getvariable{information}{title}, author=\getvariable{information}{title}]
\starttext \unknown \stoptext
There is also the \setupdocument command (a simple wrapper for the \setvariables command) which uses predefined keywords to set fields in the pdf file. You can access the values from \setupdocument command in your document with \documentvariable{<KEY>}.
\setupdocument [ metadata:title=Document title, metadata:author=Author name]
\setupinteraction[state=start]
\starttext \unknown \stoptext
Wolfgang
How does this play with \startdocument [title=Document title, author=Me] Here, I learn about metadata:title= which suggests that I could do without \setupinteraction [state=start, title={\getvariable{document}{title}}, author={\getvariable{document}{author}}] But, if I want to use the title etc. in the title page, should I do something like: \starttitlepagemakeup \getvariable{document}{metadata:title} \stoptitlepagemakeup Thanks Alan