On Monday 15 April 2002 4:40 pm, Angus Leeming wrote:
> I think that the screen label part of the patch is fine, although I've
> modified it to work with numerical natbib citations and to cache the label.
>
> Attached are my re-workings.

[snip]

I have tested this patch pretty thoroughly myself and have decided that it's 
only real shortcoming is that it results in VERY slow loading of a buffer. 
This occurs because we reload Buffer::getBibkeyList from any BibTeX files for 
each and every citation key.

The real solution is for Buffer::getBibkeyList to reload the BibTeX keys only 
when the BibTeX files change but, for now, a working alternative is to cache 
the keys used by InsetCitation.

I have created a 
        map<Buffer const *, bool> loading_buffer;
which is set to 
        loading_buffer[buffer] = false;
in InsetCitation::edit().

It is used within getNatbibLabel to ascertain whether to reload the 
Buffer::getBibkeyList.

All works very well here, but I'd like some volunteer testers please. No 
testers, no apply...

This patch applies against current CVS.

Regards,
Angus


Attachment: insetcite.diff.gz
Description: GNU Zip compressed data

Reply via email to