lasgout...@lyx.org writes:
> revert r30531, which causes a crash when copying an inset.
>
> Basically, insets in cut stack do not have a buffer, and therefore cannot
> acess to buffer parameters. What is annoying here is that acceptChanges 
> requires this buffer params only to be able to read a font in moveItem,
> in order to read the buffer language, and I doubt this is really needed...
>
> Another change in this patch is that Inset::getLayout now returns a 
> plainLayout when the inset does not have a buffer_. This fixes a remaining 
> crash where dEPM reads isFreeSpacing() for an inset in the clipboard, but
> this looks like a fragile situation. And it will not do the right thing when
> doing depm in a freespacing inset.

The fact that we use the buffer_ member of insets for getLayout()
creates more situations where insets are not treated in the right way. I
am not sure how we can get out of this situation. A solution would be to
add a Inset::getLayout(Buffer) method, but this still feels like a hack.

Thoughts?

JMarc

Reply via email to