I am writing a layout for a class file.

The corresponding class file specifies several \RequirePackage calls with the [dvips] option, and hence trying to compile the document using pdflatex or any of the other pdf renderers fails.

Unfortunately, pdf output is the default in Lyx. Is there a way to set the default output format to dvi in the layout file?


From Help > Customization:

OutputFormat [format] The file format (as defined in the LyX preferences) produced by this document class. It is mainly useful when OutputType is literate and one wants to define a new type of literate document. The format is reset to “docbook” or “latex” when the corresponding OutputType parameter is encountered.

So in your layout file you could put

OutputFormat dvi
  • When I do this, the document starts off with the View/Update buttons in a disabled state. Then if I press Tools -> Document Settings and go to Output and set the default format to DVI, it seems to produce documents that I cannot open. If however, I do not include the OutputFormat dvi line and just set the output type to DVI manually, it works. – parsiad Jan 18 '14 at 21:20
  • @par I can reproduce. It is either a bug in LyX or a misunderstanding on my part. You could send an email (linking to this question) to lyx-users@lists.lyx.org or if you think it's a bug file a report at lyx.org/trac – scottkosty Jan 18 '14 at 22:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.