#include "BREPPlugin_IImport.hxx"
// KERNEL includes
+#include <Basics_DirUtils.hxx>
#include <utilities.h>
// GEOM includes
}
//Make a Python command
+ std::string convFileName = Kernel_Utils::BackSlashToSlash(theFileName.ToCString());
GEOM::TPythonDump(aFunction) << "geompy.ExportBREP(" << theOriginal << ", \""
- << theFileName.ToCString() << "\" )";
+ << convFileName.c_str() << "\" )";
SetErrorCode(OK);
}
//Make a Python command
GEOM::TPythonDump pd (aFunction);
- pd << aSeq << " = geompy.ImportBREP(\"" << theFileName.ToCString() << "\" )";
+ std::string convFileName = Kernel_Utils::BackSlashToSlash( theFileName.ToCString() );
+ pd << aSeq << " = geompy.ImportBREP(\"" << convFileName.c_str() << "\" )";
SetErrorCode(OK);
return aSeq;
#include "IGESPlugin_IImport.hxx"
// KERNEL includes
+#include <Basics_DirUtils.hxx>
#include <utilities.h>
// GEOM includes
}
//Make a Python command
+ std::string convFileName = Kernel_Utils::BackSlashToSlash(theFileName.ToCString());
GEOM::TPythonDump(aFunction) << "geompy.ExportIGES(" << theOriginal << ", \""
- << theFileName.ToCString() << "\", \"" << theVersion.ToCString() << "\" )";
+ << convFileName.c_str() << "\", \"" << theVersion.ToCString() << "\" )";
SetErrorCode(OK);
}
//Make a Python command
GEOM::TPythonDump pd (aFunction);
+ std::string convFileName = Kernel_Utils::BackSlashToSlash(theFileName.ToCString());
if( theIsIgnoreUnits )
- pd << aSeq << " = geompy.ImportIGES(\"" << theFileName.ToCString() << "\", True)";
+ pd << aSeq << " = geompy.ImportIGES(\"" << convFileName.c_str() << "\", True)";
else
- pd << aSeq << " = geompy.ImportIGES(\"" << theFileName.ToCString() << "\")";
+ pd << aSeq << " = geompy.ImportIGES(\"" << convFileName.c_str() << "\")";
SetErrorCode(OK);
return aSeq;
#include "STEPPlugin_IImport.hxx"
// KERNEL includes
+#include <Basics_DirUtils.hxx>
#include <utilities.h>
// GEOM includes
}
//Make a Python command
+ std::string convFileName = Kernel_Utils::BackSlashToSlash(theFileName.ToCString());
GEOM::TPythonDump(aFunction) << "geompy.ExportSTEP(" << theOriginal << ", \""
- << theFileName.ToCString() << "\", " << theUnit << " )";
+ << convFileName.c_str() << "\", " << theUnit << " )";
SetErrorCode(OK);
}
//Make a Python command
GEOM::TPythonDump pd (aFunction);
- pd << aSeq << " = geompy.ImportSTEP(\"" << theFileName.ToCString() << "\", ";
+ std::string convFileName = Kernel_Utils::BackSlashToSlash( theFileName.ToCString() );
+ pd << aSeq << " = geompy.ImportSTEP(\"" << convFileName.c_str() << "\", ";
pd << (theIsIgnoreUnits ? "True" : "False");
pd << ", " << (IsCreateAssemblies ? "True" : "False");
pd << ")";
#include "STLPlugin_IImport.hxx"
// KERNEL includes
+#include <Basics_DirUtils.hxx>
#include <utilities.h>
// GEOM includes
}
//Make a Python command
+ std::string convFileName = Kernel_Utils::BackSlashToSlash(theFileName.ToCString());
GEOM::TPythonDump(aFunction) << "geompy.ExportSTL(" << theOriginal << ", \""
- << theFileName.ToCString() << "\", " << theIsASCII << ", " << theDeflection << ", "
+ << convFileName.c_str() << "\", " << theIsASCII << ", " << theDeflection << ", "
<< theIsRelative << ")";
SetErrorCode(OK);
//Make a Python command
GEOM::TPythonDump pd (aFunction);
- pd << aSeq << " = geompy.ImportSTL(\"" << theFileName.ToCString() << "\" )";
+ std::string convFileName = Kernel_Utils::BackSlashToSlash(theFileName.ToCString());
+ pd << aSeq << " = geompy.ImportSTL(\"" << convFileName.c_str() << "\" )";
SetErrorCode(OK);
return aSeq;
#include "VTKPlugin_IExport.hxx"
// KERNEL includes
+#include <Basics_DirUtils.hxx>
#include <utilities.h>
// GEOM includes
}
//Make a Python command
+ std::string convFileName = Kernel_Utils::BackSlashToSlash(theFileName.ToCString());
GEOM::TPythonDump(aFunction) << "geompy.ExportVTK(" << theOriginal << ", \""
- << theFileName.ToCString() << "\", " << theDeflection << ")";
+ << convFileName.c_str() << "\", " << theDeflection << ")";
SetErrorCode(OK);
}
#include "XAOPlugin_IImportExport.hxx"
// KERNEL includes
+#include <Basics_DirUtils.hxx>
#include <utilities.h>
#include <Utils_SALOME_Exception.hxx>
// make a Python command
GEOM::TPythonDump pd(exportFunction);
+ std::string convFileName = Kernel_Utils::BackSlashToSlash(fileName);
pd << "exported = geompy.ExportXAO(" << shape;
// list of groups
}
}
pd << "], ";
- pd << "\"" << author << "\", \"" << fileName << "\", \"" << shapeFileName << "\")";
+ pd << "\"" << author << "\", \"" << convFileName.c_str() << "\", \"" << shapeFileName << "\")";
SetErrorCode(OK);
delete xaoObject;
pd << obj << ((i < nbFields) ? ", " : "");
}
}
+ std::string convFileName = Kernel_Utils::BackSlashToSlash( fileName );
pd << "]";
- pd << ") = geompy.ImportXAO(\"" << fileName << "\")";
+ pd << ") = geompy.ImportXAO(\"" << convFileName.c_str() << "\")";
delete xaoObject;
SetErrorCode(OK);