On 19/07/10 22:06, Sam Liddicott wrote:
If I write data using <write|aux|<tuple|key|value>>, how do I get to read it back again. I've done it in a hackey way for now. I use: <write|nf-chunk|<tuple|nf-this-chunk-id|...>> when I create a label At the top of the document I have to insert a dodgy toc (for now - it can't be in the ts file). <assign|nf-chunks-index|<\table-of-contents|nf-chunk></table-of-contents>> <nf-parse-look-ahead> The toc is assigned to a variable nf-chunks-index; I have a macro nf-parse-look-ahead which navigates the toc to get back the tuples - and then defines global variables based on the first tuple member: <assign|nf-parse-look-ahead|<macro|<with|nf-chunks-index|<look-up|<look-up|<look-up|<value|nf-chunks-index>|0>|1>|4>|<with|i|0|<while|<less|<value|i>|<get-arity|<value|nf-chunks-index>>>|<assign|<merge|nfla-|<look-up|<look-up|<value|nf-chunks-index>|<value|i>>|0>>|<look-up|<value|nf-chunks-index>|<value|i>>><assign|i|<plus|<value|i>|1>>>>>>> So (as long as I "update" my document) I can tell if a future chunk is (probably) (going to be) defined by looking for the variable defined. I've tried guessing how the depracted "env" command works, and using extern functions to replicate what the toc stuff does but it's not obvious. This filthy hack will do for now... But please someone tell me the inverse of <write|aux Sam --
Sam's signature |
Archive powered by MHonArc 2.6.19.