I just realized that the same problem exists for loading ldr files. Patch below.
I missed this earlier, because I didn't think it was possible to read
ldr files at all, since nothing happened.

How much info is lost by saving to ldr instead of lcd files?
My viewport setup is lost, anything more?

/$


--- common/project.cpp  (revision 729)
+++ common/project.cpp  (arbetskopia)
@@ -1036,6 +1036,7 @@
 void Project::FileReadLDraw(File* file, Matrix* prevmat, int* nOk,
int DefColor, int* nStep, PtrArray<File>& FileArray)
 {
        char buf[1024];
+       const char* OldLocale = setlocale(LC_NUMERIC, "C");

   // Save file offset.
   lcuint32 Offset = file->GetPosition();
@@ -1133,6 +1134,7 @@

   // Restore file offset.
   file->Seek(Offset, SEEK_SET);
+  setlocale(LC_NUMERIC, OldLocale);
 }

 bool Project::DoFileSave()
_______________________________________________
Leocad mailing list
[email protected]
https://list.gerf.org/listinfo/leocad

Reply via email to