mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-01-13 10:10:33 +05:00
add a comment in dump for the disabling of publication in study
This commit is contained in:
parent
0a237be4b9
commit
4cd676f92c
@ -3818,6 +3818,8 @@ bool _pyCommand::IsMethodCall()
|
|||||||
{
|
{
|
||||||
if ( GetMethod().IsEmpty() )
|
if ( GetMethod().IsEmpty() )
|
||||||
return false;
|
return false;
|
||||||
|
if ( myString.StartsWith("#") )
|
||||||
|
return false;
|
||||||
const char* s = myString.ToCString() + GetBegPos( METHOD_IND ) + myMeth.Length() - 1;
|
const char* s = myString.ToCString() + GetBegPos( METHOD_IND ) + myMeth.Length() - 1;
|
||||||
return ( s[0] == '(' || s[1] == '(' );
|
return ( s[0] == '(' || s[1] == '(' );
|
||||||
}
|
}
|
||||||
|
@ -1002,13 +1002,16 @@ TCollection_AsciiString SMESH_Gen_i::DumpPython_impl
|
|||||||
const TCollection_AsciiString anOldGen ( SMESH::TPythonDump::SMESHGenName() );
|
const TCollection_AsciiString anOldGen ( SMESH::TPythonDump::SMESHGenName() );
|
||||||
const TCollection_AsciiString helper; // to comfortably append C strings to TCollection_AsciiString
|
const TCollection_AsciiString helper; // to comfortably append C strings to TCollection_AsciiString
|
||||||
const TCollection_AsciiString tab( isMultiFile ? "\t" : "" ), nt = helper + "\n" + tab;
|
const TCollection_AsciiString tab( isMultiFile ? "\t" : "" ), nt = helper + "\n" + tab;
|
||||||
|
TCollection_AsciiString optionalComment;
|
||||||
|
|
||||||
std::list< TCollection_AsciiString > lines; // lines of a script
|
std::list< TCollection_AsciiString > lines; // lines of a script
|
||||||
std::list< TCollection_AsciiString >::iterator linesIt;
|
std::list< TCollection_AsciiString >::iterator linesIt;
|
||||||
|
|
||||||
lines.push_back( aSMESHGen + " = smeshBuilder.New()" );
|
lines.push_back( aSMESHGen + " = smeshBuilder.New()" );
|
||||||
if ( !isPublished )
|
if ( isPublished )
|
||||||
lines.push_back( aSMESHGen + ".SetEnablePublish( False )" );
|
optionalComment = helper + "#";
|
||||||
|
lines.push_back( optionalComment + aSMESHGen + ".SetEnablePublish( False ) # Set to False to avoid publish in study if not needed or in some particular situations:" );
|
||||||
|
lines.push_back( " # multiples meshes built in parallel, complex and numerous mesh edition (performance)" );
|
||||||
lines.push_back( helper + "aFilterManager = " + aSMESHGen + ".CreateFilterManager()" );
|
lines.push_back( helper + "aFilterManager = " + aSMESHGen + ".CreateFilterManager()" );
|
||||||
lines.push_back( helper + "aMeasurements = " + aSMESHGen + ".CreateMeasurements()" );
|
lines.push_back( helper + "aMeasurements = " + aSMESHGen + ".CreateMeasurements()" );
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user