Hello,
I'm using the listings package to display source code in a Lyx document. See
http://www.texnik.de/listings/listings.phtml, for example.
The way I use this is to open an ERT box that holds
\begin_inset ERT
status Open
\layout Standard
\backslash
begin{lstlisting}[language=Octave,%
\newline
alsolanguage=,%
\newline
label=sql:label2,caption=caption2]
\newline
\layout Standard
<FILE INSERTED HERE>
\backslash
end{lstlisting}
\end_inset
Then I use INSERT -> INSERT_FILE -> ASCII As Lines to insert a file in the
spot noted above. The problem is that the lines of the inserted file don't
have a \newline at their ends, which results in the code display being
doublespaced rather than single as in the original. I can add them
manually, but is there a way to make this automatic.
Thanks in advance, Michael