breakParagraphConservative(
buffer.params(),
insertion, i, j);
+ break;
}
}
}
}
}
+ InsetText in(buffer);
// Make sure there is no class difference.
- InsetText in;
+ in.paragraphs().clear();
// This works without copying any paragraph data because we have
// a specialized swap method for ParagraphList. This is important
// since we store pointers to insets at some places and we don't
// merge the first par of the insertion with the current par
mergeParagraph(buffer.params(), pars, pit);
}
+ //FIXME: We should call setBuffer() on each inserted paragraph.
+ // instead, we call setBuffer() for the main inset at the beginning
+ // of updateLabels()
pit_type last_paste = pit + insertion.size() - 1;
// some kind of garbage collection there, or a shared_ptr, then this
// would not be needed.
static Buffer * buffer = theBufferList().newBuffer(
- FileName::tempName().absFilename());
+ FileName::tempName().absFilename() + "_clipboard.internal");
buffer->setUnnamed(true);
buffer->paragraphs() = paragraphs;
+ buffer->inset().setBuffer(*buffer);
buffer->params().setDocumentClass(docclass);
ostringstream lyx;
if (buffer->write(lyx))