Subject: Re: Crossreferencing From: Matthias Clasen <mclasen@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx> Date: Sat Mar 29 10:26:17 1997 EST 
Sorry, I just posted this under a wrong subject: Thanks a lot, Tony Grahams stylesheet does exactly what I wanted  this list might become a great place to learn more about DSSSL ! Let me try to learn a bit more by making my first question a bit more complicated. I would like the document (using the sample DTD posted by Tony Graham earlier in this thread): <test> <theorem id="theorem1">The earth is flat</theorem> <theorem id="theorem2">The stork didn't really bring me</theorem> <proof of="theorem2">If the stork brought me, I wouldn't need this belly button</proof> <proof of="theorem1">Someone told me</proof> </test> To be formatted roughly like this: Theorem 1: The earth is flat Theorem 2: The stork didn't really bring me Proof: If the stork brought me, I wouldn't need this belly button Proof of 1: Someone told me I.e. I want the `of ' part in proof to be omitted, if it is immediately following the theorem. So the task is to determine if the node immediately before the `proof' element is the one the `of' attribute is referring to. If I understood the semantics of the ipreced function in 10.2.3 correctly, the following modification of the proofrelated part of Tony Grahams stylesheet should do what I want: (element PROOF (make paragraph (make sequence (if (equal? (attributestring "OF") (attributestring "ID" (ipreced))) ; proof directly following theorem, omit number (literal "Proof:" ) ; proof not directly following theorem (withmode theorem (processelementwithid (attributestring "OF")))) (processchildren)))) But I can't try this as Jade does not understand `ipreced'. This leads to some questions: 1) Is my idea correct ? 2) Is there a way to do it within the current limitations of Jade ? 3) All these questions about crossreferencing made me remember a Latexstyle called varioref which allows `intelligent pagereferences' which print out text like `on this page', `on the next page', `on the previous page'. It might even be aware if the reference and the referent are on one spread or not. How would one handle things like that in DSSSL ? Is this possible at all (since the pagebreaks depend on the formatting algorithms which are not part of DSSSL) ? Looking forward for more enlightenment, Matthias
Current Thread 


< Previous  Index  Next > 

Re: Crossreferencing, James Clark  Thread  Re: Crossreferencing, Sebastian Rahtz 
Re: Orthoganlity Questions, Paul Prescod  Date  Re: Crossreferencing, Sebastian Rahtz 
Month 