2014-05-14 21:18 GMT+02:00 Richard Heck: > This: > > > Todo: this routine can currently handle only one mandatory argument > of envi > ''' > + end_layout = find_end_of_layout(document.body, line) > lineERT = line > endn = line > loop = 1 > - while lineERT != -1 and n < nmax + 1: > - lineERT = find_token(document.body, "\\begin_inset ERT", lineERT) > - if environment == False and lineERT != -1: > + while n < nmax + 1: > + lineERT = find_token(document.body, "\\begin_inset ERT", lineERT, > end_lay > + if lineERT == -1: > + break > > will solve some of that problem. >
Good. Note that there is a second search for ERT inset in that method (check for "lineERT2"), which probably needs similar handling. But I see what you mean about all the hard-coding. I may just try to > re-write the method. But without any comments it is hard to know what is > supposed to be happening. > That would be great. I think I understand a bit of it, so please ask if things are unclear. For the time being, the fix above should go in, I think. Jürgen > > Richard > >