Marcelo Acuña writes:
[> Helga writes:]
> > 0. Backup the .lyx file, in case the process goes
> > wrong.
> > 1. Look at the lyx file, check what an ERT
> > containing
> >     ~--- looks like.  My example is for lyx 1.4
> > 2. Use a powerful text editor on the .lyx file, tell
> >      it to replace every occurence of --- with:
> > \begin_inset ERT
> > status collapsed
> >
> > \begin_layout Standard
> > ~---
> > \end_layout
> >
> > \end_inset
> >
> >
> > I.e.
> > aaa---bbb
> > should become
> >
> > aaa
> > \begin_inset ERT
> > status collapsed
> >
> > \begin_layout Standard
> > ~---
> > \end_layout
> >
> > \end_inset
> >
> > bbb

> Helge, what good text editor ---in Linux--- can I to
> use for this?

Here is the regex that should work with vim (not tested). You would open 
a copy of the file, type ":" and then enter this (one line):

%s/---/\r\\begin_inset ERT\rstatus Collapsed\r\r\\begin_layout 
Standard\r~---\r\\end_layout\r\r\\end_inset\r\r/g

Then ":" and "sq" to save and quit.

(BTW, this cut-and-paste solution had been suggested already for this 
specific problem -- about two weeks ago.)  :-)

-Kevin

-- 
Kevin Pfeiffer <[EMAIL PROTECTED]>
Tiros-Translations

Reply via email to