On Tue, 21 Jan 2003, Tomas Frydrych wrote:

> 
> Hi Martin,
> 
> I would probably prefer if the endnotes and footnotes share as much 
> code as possible for the sake of future maintanance.
> 

I would too but I'd very much like to get Pat Lam's opinion before 
launching into this. He might even want to do the work :-)


> > Also we have be care about
> > deleting references. It is quite common to have multiple references to
> > the same end note. Do we want to maintaina reference count on the
> > endnote strux and delete when it drops to zero? (we can do this via
> > attribute/value pair). We might also want to delete the original
> > reference which would delete the EndNote text unless we put in special
> > purpose code in the piecetable.. 
> 
> The way multiple references are handled in Word is by using 
> NOTEREF field: you bookmark the primary reference, and then 
> when you want to refer to the same note again, you insert a field 
> {NOTEREF "my_bookmark"}. This works for both footnotes and 
> endnotes, and together with the PAGEREF field in case of footnotes 
> it is rather powerful. The bigest downside is that if you delete the 
> note or the reference bookmark, all the other references turn into 
> message "Error: bookmark not defined!"; tracking and fixing it 
> through a 250 page manuscript is a minor nightmare.
> 

He He. I was just think of a rather easy solution to this for us. (Just 
scan the doc for fields with identical footnote-id's and delete them 
inside a undo GLOB). It appears MS just bails out :-) 

> It would be invaluable if we could devise of mechanism that would 
> allow to insert multiple references to both endnotes and footnotes, 
> and warn you if you try to delete a primary reference which has 
> secondary references attached to it.
>

We could use the refcounting attribute idea to warn or just remove them 
upon deleting the footnote/endnote anchor.
 
> If we go down this road, the format of the secondary references 
> should be customisable so that the reference could appear either as 
> the note number or the number of the page on which the primary 
> reference is, so that you could easily create things likel 'see note {3} 
> on page {1}'.
> 

Yep. We could do this fancy stuff quite easily. Just a new type of type 
of field with two parameters. The footnote-id and the type of reference 
required. These would just be two attributes. The automatically 
updating feilds framework we put together would simply look up the 
footnote via it's footnote-id attribute and decide what value to give it 
via a new attribute (say footnote-type with values 
"pos_in_doc","page_number", "pos_on_page" etc...) 

Cheers

Martin


Reply via email to