Bernhard Roider wrote:

>> Yes. We need to convert all file tools to docstring. The only reason why
>> it has not happened so far is that we need the string versions in some
>> parts of the code that cannot be changed to docstring because of regexes
>> (some bibtex stuff).
>> 
> 
> Is it really needed to search the bibtex entries with regex?

No, but it is currently done like that. And in the logfile case we have no
other choice. Note that I agree that we need to do this docstring
conversion anyway, this is simply the reason why it did not happen so far.

> did you see 
> my patch from Sunday concerning the bibtex parser?

Yes, but I had no time to look at it.

> it contains a new 
> parser that extracts all fields of each bibtex entry. For now it copies
> the fields into one long docstring to get the same result as now. But this
> can be changed. Using a more complex structure makes it possible to e.g.
> let the user choose in which fields to search the specified text.

I can promise you that it is very easy to make any bibtex parser fail badly
for reasonable input, simply because bibtex is an awful format without any
formal grammar. Therefore this is somethig I don't really like to see in
LyX, using an external program that does this well would be better IMHO.
I have made good experiences with bibtool, and bugzilla has an experiemtal
patch for using it in LyX.


Georg

Reply via email to