}
text_.setCursor(cur.top(), pit, pos);
- cur.clearSelection();
cur.finishUndo();
}
// environment. Standard collapsable insets should not
// redefine this, non-standard ones may call this.
InsetLayout const & il = getLayout();
+ if (il.forceOwnlines())
+ os << breakln;
if (!il.latexname().empty()) {
if (il.latextype() == InsetLayout::COMMAND) {
// FIXME UNICODE
+ // FIXME \protect should only be used for fragile
+ // commands, but we do not provide this information yet.
if (runparams.moving_arg)
os << "\\protect";
os << '\\' << from_utf8(il.latexname());
os << breakln;
else
os << safebreakln;
- os << "\\end{" << from_utf8(il.latexname()) << "}\n";
+ os << "\\end{" << from_utf8(il.latexname()) << "}" << breakln;
if (!il.isDisplay())
os.protectSpace(true);
}
}
+ if (il.forceOwnlines())
+ os << breakln;
}