]> SALOME platform Git repositories - modules/hydro.git/commitdiff
Salome HOME
Bug #486: SyntaxError: can't assign to operator after dump python.
authormzn <mzn@opencascade.com>
Wed, 5 Nov 2014 12:53:02 +0000 (12:53 +0000)
committermzn <mzn@opencascade.com>
Wed, 5 Nov 2014 12:53:02 +0000 (12:53 +0000)
src/HYDROData/HYDROData_Entity.cxx

index 30c2aa948705b81736dcf7e8183868795fbe6e36..ba2cb941f77c21b43c12ba93f98eb9ea7e5c00b9 100644 (file)
@@ -46,7 +46,10 @@ QString HYDROData_Entity::GetName() const
 
 QString HYDROData_Entity::GetObjPyName() const
 {
-  return GetName().replace(" ", "_");
+  QString aName = GetName();
+  aName.replace(QRegExp("[\\W]"), "_");
+
+  return aName;
 }
 
 void HYDROData_Entity::SetName(const QString& theName)