- string const saveflt = cnts.current_float();
- bool const savesubflt = cnts.isSubfloat();
-
- 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;
- setSubfloat(subflt);
-
- // Tell to captions what the current float is
- cnts.current_float(params().type);
- cnts.isSubfloat(subflt);
-
- InsetCollapsable::updateBuffer(it, utype);
-
- //reset afterwards
- cnts.current_float(saveflt);
- if (utype == OutputUpdate)
- cnts.restoreLastCounter();
- cnts.isSubfloat(savesubflt);
+ return alignment;
+}
+
+
+LyXAlignment InsetFloat::contentAlignment() const
+{
+ LyXAlignment align = LYX_ALIGN_NONE;
+ string alignment = getAlignment();
+ if (alignment == "left")
+ align = LYX_ALIGN_LEFT;
+ else if (alignment == "center")
+ align = LYX_ALIGN_CENTER;
+ else if (alignment == "right")
+ align = LYX_ALIGN_RIGHT;
+
+ return align;