]> git.lyx.org Git - lyx.git/blobdiff - src/exporter.C
lyxstring compile fixes ; small stuff
[lyx.git] / src / exporter.C
index 26952a7b64ae7348533b981590d2d61c61a648fa..46ec172d73b3f780e90b29d2ac9fa2a36b663cc0 100644 (file)
@@ -4,7 +4,7 @@
  *           LyX, The Document Processor
  *        
  *           Copyright 1995 Matthias Ettrich
- *           Copyright 1995-2000 The LyX Team.
+ *           Copyright 1995-2001 The LyX Team.
  *
  * ====================================================== */
 
@@ -23,6 +23,7 @@
 #include "lyxrc.h"
 #include "converter.h"
 #include "lyx_gui_misc.h" //WriteAlert
+#include "gettext.h"
 
 using std::vector;
 using std::find;
@@ -70,7 +71,11 @@ bool Exporter::Export(Buffer * buffer, string const & format,
        // LaTeX backend
        else if (backend_format == format)
                buffer->makeLaTeXFile(filename, string(), true);
-       else
+       else if (contains(buffer->filepath, ' ')) {
+               WriteAlert(_("Cannot run latex."),
+                          _("The path to the lyx file cannot contain spaces."));
+               return false;
+       } else
                buffer->makeLaTeXFile(filename, buffer->filepath, false);
 
        string outfile_base = (put_in_tempdir)