Do not output empty \item's or \commands with change tracking

unless "show in output" is selected.

Fixes #2861
This commit is contained in:
Juergen Spitzmueller 2019-12-26 12:26:32 +01:00
parent 90ae998287
commit d644ba0087

View File

@ -742,6 +742,12 @@ void TeXOnePar(Buffer const & buf,
if (style.inpreamble && !force)
return;
// Do not output empty commands if the whole paragraph has
// been deleted with ct and changes are not output.
if (!runparams_in.for_search && style.latextype != LATEX_ENVIRONMENT
&& par.isDeleted(0, par.size()) && !bparams.output_changes)
return;
LYXERR(Debug::LATEX, "TeXOnePar for paragraph " << pit << " ptr " << &par << " '"
<< everypar << "'");