diff options
Diffstat (limited to 'tex/context/base/strc-doc.mkiv')
-rw-r--r-- | tex/context/base/strc-doc.mkiv | 18 |
1 files changed, 16 insertions, 2 deletions
diff --git a/tex/context/base/strc-doc.mkiv b/tex/context/base/strc-doc.mkiv index a677c4d2d..7813eb7f8 100644 --- a/tex/context/base/strc-doc.mkiv +++ b/tex/context/base/strc-doc.mkiv @@ -60,8 +60,21 @@ \c!command=\showstructuredata] % maybe flags for list, bm, mark -% -% hm messed up + +\def\structurereferenceprefixon {+} +\def\structurereferenceprefixoff{-} + +\def\setstructurereferenceprefix + {\ifx\currentstructurereferenceprefix\empty + % nothing + \else\ifx\currentstructurereferenceprefix\structurereferenceprefixon + \setupglobalreferenceprefix[\currentstructurereference]% + \else\ifx\currentstructurereferenceprefix\structurereferenceprefixoff + \setupglobalreferenceprefix[]% + \else + \setupglobalreferenceprefix[\currentstructurereferenceprefix]% + \fi\fi\fi + \let\currentstructurereferenceprefix\referenceprefix} \def\dostructurecomponent[#1][#2]% #1=interfaced-settings, #2=optional user data (not yet supported) {\begingroup @@ -115,6 +128,7 @@ \globallet\currentstructurecoding\s!tex \fi \setnextinternalreference + \setstructurereferenceprefix \xdef\currentstructurenumber{\ctxlua{ % todo: combine with next call, adapt marks accordingly structures.sections.somelevel { references = { |