On Mon, May 21, 2007 at 11:50:08PM +0200, Michael Gerz wrote: > [EMAIL PROTECTED] schrieb: > >Author: spitz > >Date: Fri May 18 11:21:07 2007 > >New Revision: 18399 > > > >Modified: lyx-devel/trunk/src/Cursor.cpp > >URL: http://www.lyx.org/trac/file/lyx-devel/trunk/src/Cursor.cpp?rev=18399 > >============================================================================== > >--- lyx-devel/trunk/src/Cursor.cpp (original) > >+++ lyx-devel/trunk/src/Cursor.cpp Fri May 18 11:21:07 2007 > >@@ -249,8 +249,9 @@ > > { > > odocstringstream ods; > > ods << '\n'; > >- // only add blank line if we're not in an ERT inset > >- if (par.ownerCode() != Inset::ERT_CODE) > >+ // only add blank line if we're not in an ERT or Listings > >inset > >+ if (par.ownerCode() != Inset::ERT_CODE > >+ && par.ownerCode() != Inset::LISTINGS_CODE) > > ods << '\n'; > > return ods.str(); > > } > > > > > It frightens me to see code like this in Cursor.cpp.
Yes. There should be a virtual function in InsetBase for that (and probably any other usage of Inset::*_CODE for that matter) Andre'