par.cleanChanges();
change = Change(Change::UNCHANGED);
} else if (token == "\\change_inserted") {
- lex.nextToken();
+ lex.eatLine();
std::istringstream is(lex.getString());
int aid;
lyx::time_type ct;
is >> aid >> ct;
change = Change(Change::INSERTED, bp.author_map[aid], ct);
} else if (token == "\\change_deleted") {
- lex.nextToken();
+ lex.eatLine();
std::istringstream is(lex.getString());
int aid;
lyx::time_type ct;
<< "Missing \\end_layout.\n";
break;
}
- lyxerr << "Paragraph token unknown: `" << token << '\'' << endl;
}
}
&& !isFirstInSequence(pit, pars_)))
&& align == LYX_ALIGN_BLOCK
&& !par.params().noindent()
- // in tabulars and ert paragraphs are never indented!
+ // in charstyles, tabulars and ert paragraphs are never indented!
&& (par.ownerCode() != InsetBase::TEXT_CODE
- && par.ownerCode() != InsetBase::ERT_CODE)
+ && par.ownerCode() != InsetBase::ERT_CODE
+ && par.ownerCode() != InsetBase::CHARSTYLE_CODE)
&& (par.layout() != tclass.defaultLayout()
|| bv()->buffer()->params().paragraph_separation ==
BufferParams::PARSEP_INDENT))
int LyXText::rightMargin(Paragraph const & par) const
{
- LyXTextClass const & tclass = bv()->buffer()->params().getLyXTextClass();
-
// We do not want rightmargins on inner texts.
if (bv()->text() != this)
return 0;
+ LyXTextClass const & tclass = bv()->buffer()->params().getLyXTextClass();
int const r_margin =
::rightMargin()
+ font_metrics::signedWidth(tclass.rightmargin(),
* 4 / (par.getDepth() + 4);
return r_margin;
-
}
&& (pars_[cpit].layout() == pars_[tmppit].layout()
|| pars_[tmppit].layout() == tclass.defaultLayout())
&& pars_[cpit].getAlign() == pars_[tmppit].getAlign()) {
- mergeParagraph(bufparams, buf.paragraphs(), cpit);
+ mergeParagraph(bufparams, pars_, cpit);
if (cur.pos() != 0 && pars_[cpit].isSeparator(cur.pos() - 1))
--cur.pos();
else if (y > yo_ + descent())
yy = y - yo_ - descent();
- lyxerr << " xo_=" << xo_ << " yo_=" << yo_
+ lyxerr << " xo_=" << xo_ << " yo_=" << yo_
<< " width_=" << width_ << " ascent=" << ascent()
- << " descent=" << descent()
+ << " descent=" << descent()
<< " dist=" << xx+yy <<endl;
return xx + yy;
}