On 07/17/2010 01:14 PM, Vincent van Ravesteijn wrote:
Richard,
Author: rgheck
Date: Wed Apr 7 18:15:26 2010
New Revision: 34080
URL: http://www.lyx.org/trac/changeset/34080
Log:
Fix bug #6611. This also gives us a more robust fall-back in case we are
completely unable to load a text class. At least not very long ago, if
we were unable even to load article, we would crash. Not now. We will
ALWAYS have at least a really basic class (nothing but Standard!)
available.
+
+LayoutFileIndex LayoutFileList::addEmptyClass(string const& textclass)
+{
+ FileName const tempLayout = FileName::tempName();
+ ofstream ofs(tempLayout.toFilesystemEncoding().c_str());
+ // This writes a very basic class, but it also attempts to include
+ // stdclass.inc. That would give us something moderately usable.
+ ofs<< "# This layout is automatically generated\n"
+ "# \\DeclareLaTeXClass{"<< textclass<< "}\n\n"
+ "Format 26\n"
Are you sure you want this hardcoded format number ? To load this
file, we now need to run layout2layout, which might not be possible
(e.g. if python is not installed). Then we crash.
OK, I took care of this and the other issues you noticed. That said,
aren't there lots of things that fail in LyX if python isn't installed?
E.g, configure?
rh