mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-23 13:31:49 +00:00
Fix line count off-by-one for single-par verbatims
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@21293 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
bc86ac1804
commit
af84c0957d
@ -254,15 +254,18 @@ TeXOnePar(Buffer const & buf,
|
||||
LayoutPtr style;
|
||||
|
||||
if (runparams_in.verbatim) {
|
||||
Font const outerfont =
|
||||
outerFont(std::distance(paragraphs.begin(), pit),
|
||||
paragraphs);
|
||||
int dist = std::distance(paragraphs.begin(), pit);
|
||||
Font const outerfont = outerFont(dist, paragraphs);
|
||||
|
||||
// No newline if only one paragraph in this lyxtext
|
||||
if (dist > 0) {
|
||||
os << '\n';
|
||||
texrow.newline();
|
||||
}
|
||||
|
||||
/*bool need_par = */ pit->latex(buf, bparams, outerfont,
|
||||
os, texrow, runparams_in);
|
||||
|
||||
os << '\n';
|
||||
texrow.newline();
|
||||
return ++pit;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user