> > > I wonder, whether there is a lyx function that can be used to place the
> > > cursor in the relevant line. 
> 
> > one possibility would be use paragraph-goto but it will be quite tricky 
> > to get the right number of paragraph. not every indexing number here has its
> > own counter part in visible document etc...
> 
> Is there some documentation for paragraph-goto? 

doxy is currently there (it will not help you:)

> What argument does it expect (integer number, I suppose).

paragraph id.

> How is a "paragraph" defined in the lyx-source? Is it possible to parse it
> to find out (e.g. by counting the blank lines before the line-in-question?

no such simple heuristics will help. as i said this will be very tricky.
this id can be different even for different loading sequence of lyx documents.
i personally think it will take much less time to hack lyx source and add
new lfun which will iterate through all paragraphs and do some string
comparison given from argument. if match then return id which you will jump on.

> > > (There is a function called "server-goto-file-row", however, I did
> > > not find out what exactly it is supposed to do or what arguments it
> > > expects.)
> > purpose of this function is to set the cursor based on the given TeX
> > source row. 
> 
> This means the LyX-readable tex source in the tmp dir, not a source
> generated with File>Export, right?
> 
> What arguments does this function expcect? Something like
> 
>    server-goto-file-row /tmp/lyx_tmpdir3193YwEozQ/lyx_tmpbuf0/test.tex 320
>    
> ?   

no the second argument is .lyx file, not the tex filename.

....
> as powerful replacement for the missing regular-expression search and
> search-and-replace-in-math features.

there was already some patch for advanced search in lyx, but Tommaso seem
to be busy now so it seems it wont be part of lyx 1.6.

> So it looks like paragraph-goto is the way to go (until we get a row-goto
> lfun alongside it).

either server-goto-file-row or write complete new lfun for your usage. both
paths will be for adventurous spirit though :)

pavel

Reply via email to