}
+bool Paragraph::parbreakIsNewline() const
+{
+ return inInset().getLayout().parbreakIsNewline() || d->layout_->parbreak_is_newline;
+}
+
+
bool Paragraph::isPartOfTextSequence() const
{
for (pos_type i = 0; i < size(); ++i) {
pos_type body_pos = beginOfBody();
unsigned int column = 0;
- // If we are inside an non inheritFont() inset, the real outerfont is local_font
- Font const real_outerfont = (!inInset().inheritFont()
- && runparams.local_font != nullptr)
- ? Font(runparams.local_font->fontInfo()) : outerfont;
+ // If we are inside an non inheritFont() inset, the outerfont is the default font
+ Font const real_outerfont =
+ inInset().inheritFont() ? outerfont : Font(bparams.documentClass().defaultfont());
if (body_pos > 0) {
// the optional argument is kept in curly brackets in
continue;
if (ins->needsCProtection(maintext, fragile))
return true;
- // Now check math environments
- InsetMath const * im = ins->asInsetMath();
- if (!im || im->cell(0).empty())
- continue;
- switch(im->cell(0)[0]->lyxCode()) {
- case MATH_AMSARRAY_CODE:
- case MATH_SUBSTACK_CODE:
- case MATH_ENV_CODE:
- case MATH_XYMATRIX_CODE:
- // these need cprotection
- return true;
- default:
- break;
- }
}
return false;