Hello, My co-author and I are trying to typeset a computer programming book with Lyx. We're able to create fancy colored boxes to display computer code with the following:
New Color Box Type cBoxA1colback=gray!25!white,colbacktitle=black, colframe=black!75!black, fonttitle=\bfseries, title=\listno\,#1, width=\textwidth The goal is to display programming code noted below in these boxes. Our book has some 200 code boxes, so we need a very efficient method to accomplish this. But our efforts fails. If we select Insert/Custom Inset/Colored Box1 and enter plain text into the custom colored box, it compiles with this error, LaTex Error: Missing \begin{document}, but properly displays the box in PDF. If we enter either of the first two lines of the sample code below, e.g.: .../site/src$ mkdir n_dbs .../site/src$ cd n_dbs ...the system compiles with the missing begin document error, but displays properly in PDF. But if we enter both of those lines, much less the full sample code stanza shown below, the system throws errors (see below sample code) and fails to compile. So now we're stuck. We're at a total loss as to how to solve this problem. Please help. Many thanks, LRP SAMPLE CODE .../site/src$ mkdir n_dbs .../site/src$ cd n_dbs .../n_dbs$ vim nnote_db_mnesia.erl ... -module(nnote_db_mnesia). -record(note, { id = create_id(), user_id, date = calendar:universal_time(), type, event, source, topic, question, tags, note }). ERROR MESSAGES LaTex Error: Missing \begin{document} Paragraph ended before \@item was completed Undefined control sequence Too many }'s Undefined control sequence Argument of \@iiiparbox has an extra } Paragraph ended before \@iiiparbox was complete Too many }'s Undefined control sequence Undefined control sequence ...