From 77ea3f0fc9bee048d6c7afeb03bfbae6636031a3 Mon Sep 17 00:00:00 2001 From: eap Date: Wed, 10 Aug 2011 10:21:05 +0000 Subject: [PATCH] strip trailing white spaces of the object name --- src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.cxx b/src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.cxx index da40f732a..16d484e53 100644 --- a/src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.cxx +++ b/src/StdMeshersGUI/StdMeshersGUI_ObjectReferenceParamWdg.cxx @@ -206,7 +206,7 @@ void StdMeshersGUI_ObjectReferenceParamWdg::SetObject(CORBA::Object_ptr obj) sobj = SMESH::FindSObject (obj); if ( sobj ) { std::string name = sobj->GetName(); - myObjNameLineEdit->setText( name.c_str() ); + myObjNameLineEdit->setText( QString( name.c_str() ).trimmed() ); myObjNameLineEdit->setStyleSheet(""); myObjects.push_back( CORBA::Object::_duplicate( obj )); myParamValue = sobj->GetID().c_str(); @@ -241,7 +241,7 @@ void StdMeshersGUI_ObjectReferenceParamWdg::SetObjects(SMESH::string_array_var& text += " "; else text = ""; - text += name.c_str(); + text += QString( name.c_str() ).trimmed(); myObjNameLineEdit->setText( text ); myObjNameLineEdit->setStyleSheet(""); myObjects.push_back( anObj );