Well, here it is. Fixes one part of bug 4927. There's a remaining problem on conversion of onld subfigs with LaTeX content (e.g. \label). I'll fix that in a second step.
There's
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@25148
a592a061-630c-0410-9148-
cb99ea01b6c8
i = 0
while 1:
# whitespace intended (exclude \\begin_inset FloatList)
- i = find_token(document.body, '\\begin_inset Float ', i)
+ i = find_tokens(document.body, ['\\begin_inset Float ', '\\begin_inset Wrap'], i)
if i == -1:
return
j = 0
string const saveflt = cnts.current_float();
bool const savesubflt = cnts.isSubfloat();
- bool const subflt = it.innerInsetOfType(FLOAT_CODE);
+ bool const subflt = (it.innerInsetOfType(FLOAT_CODE)
+ || it.innerInsetOfType(WRAP_CODE));
// floats can only embed subfloats of their own kind
if (subflt)
params_.type = saveflt;
bool InsetWrap::insetAllowed(InsetCode code) const
{
switch(code) {
- case FLOAT_CODE:
+ case WRAP_CODE:
case FOOT_CODE:
case MARGIN_CODE:
return false;