#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <TColStd_IndexedMapOfInteger.hxx>
switch ( getConstructorId() ) {
case 0 :
{
- QStringList aParameters;
- aParameters << GroupPntVecR->SpinBox_DX->text();
anObj = anOper->MakeCirclePntVecR( myPoint, myDir, getRadius() );
if ( !anObj->_is_nil() && !IsPreview() )
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, 1, GroupPntVecR->SpinBox_DX);
res = true;
break;
}
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <TColStd_IndexedMapOfInteger.hxx>
double aMajorR = GroupPoints->SpinBox_DX->value();
double aMinorR = GroupPoints->SpinBox_DY->value();
- QStringList aParameters;
- aParameters<<GroupPoints->SpinBox_DX->text();
- aParameters<<GroupPoints->SpinBox_DY->text();
-
GEOM::GEOM_ICurvesOperations_var anOper = GEOM::GEOM_ICurvesOperations::_narrow( getOperation() );
GEOM::GEOM_Object_var anObj = myMajor->_is_nil() ?
anOper->MakeEllipse ( myPoint, myDir, aMajorR, aMinorR ) :
anOper->MakeEllipseVec( myPoint, myDir, aMajorR, aMinorR, myMajor );
if ( !anObj->_is_nil() ) {
if ( !IsPreview() )
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, 2, GroupPoints->SpinBox_DX, GroupPoints->SpinBox_DY);
objects.push_back( anObj._retn() );
}
return true;
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <QLabel>
myData[ DX2 ]->value(),
myData[ DY2 ]->value(),
myData[ DZ2 ]->value() );
- QStringList aParameters;
- aParameters<<myData[X]->text();
- aParameters<<myData[Y]->text();
- aParameters<<myData[Z]->text();
- aParameters<<myData[ DX1 ]->text();
- aParameters<<myData[ DY1 ]->text();
- aParameters<<myData[ DZ1 ]->text();
- aParameters<<myData[ DX2 ]->text();
- aParameters<<myData[ DY2 ]->text();
- aParameters<<myData[ DZ2 ]->text();
-
if ( !anObj->_is_nil() ) {
if ( !IsPreview() )
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, 9,
+ myData[ X ],
+ myData[ Y ],
+ myData[ Z ],
+ myData[ DX1 ],
+ myData[ DY1 ],
+ myData[ DZ1 ],
+ myData[ DX2 ],
+ myData[ DY2 ],
+ myData[ DZ2 ]);
objects.push_back( anObj._retn() );
}
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <TColStd_MapOfInteger.hxx>
}
//=================================================================================
-// function : getSize()
+// function : getSizeAsString()
// purpose :
//=================================================================================
QString BasicGUI_PlaneDlg::getSizeAsString() const
case 1 : return Group3Pnts->SpinBox_DX->text();
case 2 : return GroupFace->SpinBox_DX->text();
case 3 : return Group2Vec->SpinBox_DX->text();
+ case 4 : return GroupLCS->SpinBox_DX->text();
}
return QString();
}
if ( !anObj->_is_nil() ) {
if ( !IsPreview() )
- anObj->SetParameters(getSizeAsString().toLatin1().constData());
+ myNoteBook->setParameters(anObj, QStringList(getSizeAsString()));
objects.push_back( anObj._retn() );
}
return res;
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <GeometryGUI.h>
}
const int id = getConstructorId();
- if(!anObj->_is_nil() && !IsPreview() && (id == GEOM_POINT_XYZ ||
+ if(!anObj->_is_nil() && !IsPreview() && (id == GEOM_POINT_XYZ ||
id == GEOM_POINT_REF ||
id == GEOM_POINT_EDGE ||
id == GEOM_POINT_SURF) ) {
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, aParameters);
}
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <TopoDS_Shape.hxx>
double dy = GroupDimensions->SpinBox_DY->value();
double dz = GroupDimensions->SpinBox_DZ->value();
- QStringList aParameters;
- aParameters << GroupDimensions->SpinBox_DX->text();
- aParameters << GroupDimensions->SpinBox_DY->text();
- aParameters << GroupDimensions->SpinBox_DZ->text();
anObj = anOper->MakeVectorDXDYDZ( dx, dy, dz );
if ( !anObj->_is_nil() && !IsPreview() )
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, 3,
+ GroupDimensions->SpinBox_DX,
+ GroupDimensions->SpinBox_DY,
+ GroupDimensions->SpinBox_DZ);
res = true;
break;
#include <SUIT_ViewManager.h>
#include <SUIT_MessageBox.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <OCCViewer_ViewModel.h>
#include <SALOME_ListIteratorOfListIO.hxx>
return objects.size() > 0;
}
- QStringList aParameters;
- aParameters << myGrp1->SpinBox1->text();
- aParameters << myGrp1->SpinBox2->text();
-
// Throw away sub-shapes not selected by user if not in preview mode
// and manual selection is active
if ( !isAllSubShapes() ) {
if ( selected.contains( QString( objStr.in() ) ) )
{
if ( !IsPreview() )
- (*anIter)->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters((*anIter), 2, myGrp1->SpinBox1, myGrp1->SpinBox2);
objects.push_back( *anIter );
}
else
{
GEOM::GEOM_Object_var anObj = GEOM::GEOM_Object::_duplicate( aList[i] );
if ( !IsPreview() )
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, 2, myGrp1->SpinBox1, myGrp1->SpinBox2);
objects.push_back( anObj._retn() );
}
}
#include <SUIT_ViewWindow.h>
#include <SUIT_ViewManager.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <OCCViewer_ViewModel.h>
myFaces[Face1], myFaces[Face2],
mySpinBox[SpinBox1]->value());
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << "" << "";
- aParameters << mySpinBox[SpinBox1]->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, mySpinBox[SpinBox1]);
res = true;
break;
case 1:
myFaces[Face1V], myFaces[Face2V],
mySpinBox[SpinBox2V]->value());
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << "" << "";
- aParameters << mySpinBox[SpinBox2U]->text();
- aParameters << "" << "";
- aParameters << mySpinBox[SpinBox2V]->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 2, mySpinBox[SpinBox2U], mySpinBox[SpinBox2V]);
res = true;
break;
default:
#include <SUIT_MessageBox.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_Application.h>
#include <LightApp_SelectionMgr.h>
if( !IsPreview() ) {
QStringList aCurrentParameters = myParameters;
aCurrentParameters << aParameters;
- anObj->SetParameters(aCurrentParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, aCurrentParameters);
}
objects.push_back( anObj._retn() );
#include <SalomeApp_Module.h>
#include <SalomeApp_Application.h>
#include <SalomeApp_Study.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <LightApp_DataOwner.h>
#include <SalomeApp_Tools.h>
// Purpose :
//================================================================
GEOMBase_Helper::GEOMBase_Helper( SUIT_Desktop* desktop )
- : myDesktop( desktop ), myViewWindow( 0 ), myDisplayer( 0 ), myCommand( 0 ), isPreview( false )
+ : myDesktop( desktop ), myViewWindow( 0 ), myDisplayer( 0 ), myCommand( 0 ), myNoteBook( 0 ), isPreview( false )
{
+ if( SalomeApp_Application* app = (SalomeApp_Application*)( SUIT_Session::session()->activeApplication() ) )
+ if( SalomeApp_Study* appStudy = dynamic_cast<SalomeApp_Study*>( app->activeStudy() ) )
+ myNoteBook = new SalomeApp_Notebook( appStudy );
}
//================================================================
delete myDisplayer;
if ( !CORBA::is_nil( myOperation ) )
myOperation->Destroy();
+
+ if( myNoteBook )
+ {
+ delete myNoteBook;
+ myNoteBook = 0;
+ }
}
//================================================================
typedef std::list<GEOM::GEOM_Object_ptr> ObjectList;
+class SalomeApp_Notebook;
class SalomeApp_Study;
class SUIT_Desktop;
class SUIT_ViewWindow;
GEOM_Displayer* getDisplayer();
SUIT_Desktop* getDesktop() const;
+protected:
+ // To do: make this field private and add method getNoteBook()
+ SalomeApp_Notebook* myNoteBook;
+
private:
char* getEntry ( GEOM::GEOM_Object_ptr ) const;
void clearShapeBuffer( GEOM::GEOM_Object_ptr );
#include <SalomeApp_Application.h>
#include <SalomeApp_DoubleSpinBox.h>
-#include <SalomeApp_Notebook.h>
#include <SalomeApp_Study.h>
#include <LightApp_Application.h>
#include <LightApp_SelectionMgr.h>
: QDialog( parent, fl ),
GEOMBase_Helper( dynamic_cast<SUIT_Desktop*>( parent ) ),
myGeomGUI( theGeometryGUI ),
- myNoteBook( 0 ),
myRBGroup( 0 )
{
setAttribute( Qt::WA_DeleteOnClose );
{
if ( myGeomGUI )
myGeomGUI->SetActiveDialogBox( 0 );
-
- if( myNoteBook )
- {
- delete myNoteBook;
- myNoteBook = 0;
- }
}
//=================================================================================
if ( !myGeomGUI && app )
myGeomGUI = dynamic_cast<GeometryGUI*>( app->module( "Geometry" ) );
- if ( !myNoteBook && app )
- if( SalomeApp_Study* appStudy = dynamic_cast<SalomeApp_Study*>( app->activeStudy() ) )
- myNoteBook = new SalomeApp_Notebook( appStudy );
-
/* init variables */
if ( myGeomGUI )
myGeomGUI->SetActiveDialogBox( this );
#include <QDialog>
class SalomeApp_DoubleSpinBox;
-class SalomeApp_Notebook;
class GeometryGUI;
class DlgRef_Skeleton;
class QSpinBox;
QButtonGroup* myRBGroup; //!< radio button group
DlgRef_Skeleton* myMainFrame; //!< dialog box's mainframe widgetx
- SalomeApp_Notebook* myNoteBook;
-
protected slots:
virtual void ClickOnCancel();
void LineEditReturnPressed();
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <TopoDS_Iterator.hxx>
if ( !anObj->_is_nil() )
{
if ( !IsPreview() )
- {
- QStringList aParameters;
- aParameters << GroupPoints->SpinBox1->text();
- aParameters << GroupPoints->SpinBox2->text();
- aParameters << GroupPoints->SpinBox3->text();
- aParameters << GroupPoints->SpinBox4->text();
- aParameters << GroupPoints->SpinBox5->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 5,
+ GroupPoints->SpinBox1,
+ GroupPoints->SpinBox2,
+ GroupPoints->SpinBox3,
+ GroupPoints->SpinBox4,
+ GroupPoints->SpinBox5);
objects.push_back( anObj._retn() );
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
//=================================================================================
bool GenerationGUI_PrismDlg::execute (ObjectList& objects)
{
- QStringList aParameters;
GEOM::GEOM_Object_var anObj;
GEOM::GEOM_I3DPrimOperations_var anOper = GEOM::GEOM_I3DPrimOperations::_narrow(getOperation());
}
if (!anObj->_is_nil() && !IsPreview())
- {
- aParameters << GroupPoints->SpinBox_DX->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, GroupPoints->SpinBox_DX );
break;
case 1:
}
if (!anObj->_is_nil() && !IsPreview())
- {
- aParameters << GroupPoints3->SpinBox_DX->text();
- aParameters << GroupPoints3->SpinBox_DY->text();
- aParameters << GroupPoints3->SpinBox_DZ->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 3,
+ GroupPoints3->SpinBox_DX,
+ GroupPoints3->SpinBox_DY,
+ GroupPoints3->SpinBox_DZ);
break;
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <TopoDS_Shape.hxx>
if (!anObj->_is_nil())
{
if (!IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupPoints->SpinBox_DX->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, GroupPoints->SpinBox_DX);
objects.push_back(anObj._retn());
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
//=================================================================================
if ( !anObj->_is_nil() )
{
if ( !IsPreview() )
- {
- QStringList aParameters;
- aParameters << GroupPoints->SpinBox_DX->text();
- aParameters << GroupPoints->SpinBox_DY->text();
- aParameters << GroupPoints->SpinBox_DZ->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 3,
+ GroupPoints->SpinBox_DX,
+ GroupPoints->SpinBox_DY,
+ GroupPoints->SpinBox_DZ);
objects.push_back( anObj._retn() );
}
#include <SUIT_ViewWindow.h>
#include <SUIT_ViewManager.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <OCCViewer_ViewModel.h>
if (!anObj->_is_nil())
{
if (!IsPreview())
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, aParameters);
objects.push_back(anObj._retn());
}
#include <SUIT_ViewWindow.h>
#include <SUIT_ViewManager.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <OCCViewer_ViewModel.h>
if (!anObj->_is_nil())
{
if (!IsPreview())
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, aParameters);
objects.push_back(anObj._retn());
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
anObj = anOper->MakeBoxDXDYDZ(x, y, z);
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupDimensions->SpinBox_DX->text();
- aParameters << GroupDimensions->SpinBox_DY->text();
- aParameters << GroupDimensions->SpinBox_DZ->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 3,
+ GroupDimensions->SpinBox_DX,
+ GroupDimensions->SpinBox_DY,
+ GroupDimensions->SpinBox_DZ);
res = true;
}
break;
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
if (!CORBA::is_nil(myPoint) && !CORBA::is_nil(myDir)) {
anObj = anOper->MakeConePntVecR1R2H(myPoint, myDir, getRadius1(), getRadius2(), getHeight());
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupPoints->SpinBox_DX->text();
- aParameters << GroupPoints->SpinBox_DY->text();
- aParameters << GroupPoints->SpinBox_DZ->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 3,
+ GroupPoints->SpinBox_DX,
+ GroupPoints->SpinBox_DY,
+ GroupPoints->SpinBox_DZ);
res = true;
}
break;
case 1:
anObj = anOper->MakeConeR1R2H(getRadius1(), getRadius2(), getHeight());
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupDimensions->SpinBox_DX->text();
- aParameters << GroupDimensions->SpinBox_DY->text();
- aParameters << GroupDimensions->SpinBox_DZ->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 3,
+ GroupDimensions->SpinBox_DX,
+ GroupDimensions->SpinBox_DY,
+ GroupDimensions->SpinBox_DZ);
res = true;
break;
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
if (!CORBA::is_nil(myPoint) && !CORBA::is_nil(myDir)) {
anObj = anOper->MakeCylinderPntVecRH(myPoint, myDir, getRadius(), getHeight());
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupPoints->SpinBox_DX->text();
- aParameters << GroupPoints->SpinBox_DY->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 2, GroupPoints->SpinBox_DX, GroupPoints->SpinBox_DY);
res = true;
}
break;
case 1:
anObj = anOper->MakeCylinderRH(getRadius(), getHeight());
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupDimensions->SpinBox_DX->text();
- aParameters << GroupDimensions->SpinBox_DY->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 2, GroupDimensions->SpinBox_DX, GroupDimensions->SpinBox_DY);
res = true;
break;
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
bool PrimitiveGUI_DiskDlg::execute (ObjectList& objects)
{
bool res = false;
- QStringList aParameters;
GEOM::GEOM_Object_var anObj;
case 0:
anObj = anOper->MakeDiskR(getRadius(), myOrientationType);
if (!anObj->_is_nil() && !IsPreview())
- {
- aParameters << GroupDimensions->SpinBox_DX->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, GroupDimensions->SpinBox_DX);
res = true;
break;
case 1:
anObj = anOper->MakeDiskPntVecR(myPoint, myDir, getRadius());
if (!anObj->_is_nil() && !IsPreview())
- {
- aParameters << GroupPntVecR->SpinBox_DX->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, GroupPntVecR->SpinBox_DX);
res = true;
break;
case 2:
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <TopoDS_Shape.hxx>
bool PrimitiveGUI_FaceDlg::execute (ObjectList& objects)
{
bool res = false;
- QStringList aParameters;
GEOM::GEOM_Object_var anObj;
GEOM::GEOM_I3DPrimOperations_var anOper = GEOM::GEOM_I3DPrimOperations::_narrow(getOperation());
anObj = anOper->MakeFaceHW(GroupDimensions->SpinBox_DX->value(),
GroupDimensions->SpinBox_DY->value(), myOrientationType);
if (!anObj->_is_nil() && !IsPreview())
- {
- aParameters << GroupDimensions->SpinBox_DX->text();
- aParameters << GroupDimensions->SpinBox_DY->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 2, GroupDimensions->SpinBox_DX, GroupDimensions->SpinBox_DY);
res = true;
break;
case 1:
anOper->MakeFaceObjHW(myEdge, GroupPlane->SpinBox_DX->value(), GroupPlane->SpinBox_DY->value()) :
anOper->MakeFaceObjHW(myFace, GroupPlane->SpinBox_DX->value(), GroupPlane->SpinBox_DY->value());
if (!anObj->_is_nil() && !IsPreview())
- {
- aParameters << GroupPlane->SpinBox_DX->text();
- aParameters << GroupPlane->SpinBox_DY->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 2, GroupPlane->SpinBox_DX, GroupPlane->SpinBox_DY);
res = true;
break;
}
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <TopoDS_Shape.hxx>
if ( !CORBA::is_nil( myPoint ) ) {
anObj = anOper->MakeSpherePntR( myPoint, getRadius() );
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupPoints->SpinBox_DX->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, GroupPoints->SpinBox_DX);
res = true;
}
break;
{
anObj = anOper->MakeSphereR( getRadius() );
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupDimensions->SpinBox_DX->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, GroupDimensions->SpinBox_DX);
res = true;
break;
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
if (!CORBA::is_nil(myPoint) && !CORBA::is_nil(myDir)) {
anObj = anOper->MakeTorusPntVecRR(myPoint, myDir, getRadius1(), getRadius2());
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupPoints->SpinBox_DX->text();
- aParameters << GroupPoints->SpinBox_DY->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 2, GroupPoints->SpinBox_DX, GroupPoints->SpinBox_DY);
res = true;
}
break;
case 1:
anObj = anOper->MakeTorusRR(getRadius1(), getRadius2());
if (!anObj->_is_nil() && !IsPreview())
- {
- QStringList aParameters;
- aParameters << GroupDimensions->SpinBox_DX->text();
- aParameters << GroupDimensions->SpinBox_DY->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 2, GroupDimensions->SpinBox_DX, GroupDimensions->SpinBox_DY);
res = true;
break;
}
#include <QtxDoubleSpinBox.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
if ( aResult )
{
if ( !IsPreview() )
- {
- QStringList aParameters;
- aParameters << "";
- aParameters << myValEdt->text();
- aParameters << "";
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, myValEdt);
objects.push_back( anObj._retn() );
}
#include <QtxDoubleSpinBox.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <SalomeApp_Study.h>
#include <SalomeApp_Tools.h>
aResult = !anObj->_is_nil();
if ( aResult && !IsPreview() )
{
- QStringList aParameters;
- aParameters << myTolEdt->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
-
+ myNoteBook->setParameters(anObj, 1, myTolEdt);
objects.push_back( anObj._retn() );
}
break;
if ( aResult )
{
if ( !IsPreview() )
- {
- QStringList aParameters;
- aParameters << myTolEdt2->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, myTolEdt2);
objects.push_back( anObj._retn() );
}
#include <QtxDoubleSpinBox.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <SUIT_Session.h>
#include <SUIT_MessageBox.h>
if ( aResult )
{
if ( !IsPreview() )
- {
- QStringList aParameters;
- aParameters << myTolEdt->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
- }
+ myNoteBook->setParameters(anObj, 1, myTolEdt);
objects.push_back( anObj._retn() );
}
}
#include <SalomeApp_Application.h>
#include <SalomeApp_DoubleSpinBox.h>
#include <SalomeApp_IntSpinBox.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
aParameters << QString( aParams[i] );
aParameters << getTexts( aParams );
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, aParameters);
}
objects.push_back( anObj._retn() );
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
if (!anObj->_is_nil()) {
if(!IsPreview())
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, aParameters);
objects.push_back(anObj._retn());
}
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
if (!anObj->_is_nil()) {
if(!IsPreview())
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, aParameters);
objects.push_back(anObj._retn());
}
#include <SUIT_ResourceMgr.h>
#include <SUIT_Session.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
//=================================================================================
anObj = anOper->OffsetShapeCopy( myObjects[i], GetOffset() );
if ( !anObj->_is_nil() ) {
if(!IsPreview()) {
- anObj->SetParameters(GroupPoints->SpinBox_DX->text().toLatin1().constData());
+ myNoteBook->setParameters(anObj, 1, GroupPoints->SpinBox_DX);
}
objects.push_back( anObj._retn() );
}
anObj = anOper->RotateCopy(myObjects[i], myAxis, GetAngle() * PI180);
if (!anObj->_is_nil()) {
if(!IsPreview()) {
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ //anObj->SetParameters(aParameters.join(":").toLatin1().constData());
}
objects.push_back(anObj._retn());
}
anObj = anOper->Rotate(myObjects[i], myAxis, GetAngle() * PI180);
if (!anObj->_is_nil()) {
if(!IsPreview()) {
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ //anObj->SetParameters(aParameters.join(":").toLatin1().constData());
updateAttributes(anObj, aParameters);
}
objects.push_back(anObj._retn());
#include <SUIT_Session.h>
#include <SUIT_ResourceMgr.h>
#include <SalomeApp_Application.h>
+#include <SalomeApp_Notebook.h>
#include <LightApp_SelectionMgr.h>
// OCCT Includes
anObj = anOper->ScaleShapeCopy(myObjects[i], myPoint, SpinBox_FX->value());
if (!anObj->_is_nil()) {
if(!IsPreview())
- anObj->SetParameters(SpinBox_FX->text().toLatin1().constData());
+ myNoteBook->setParameters(anObj, 1, SpinBox_FX);
objects.push_back(anObj._retn());
}
}
SpinBox_FY->value(), SpinBox_FZ->value());
if (!anObj->_is_nil())
if(!IsPreview()) {
- QStringList aParameters;
- aParameters<<SpinBox_FX->text();
- aParameters<<SpinBox_FY->text();
- aParameters<<SpinBox_FZ->text();
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ myNoteBook->setParameters(anObj, 3, SpinBox_FX, SpinBox_FY, SpinBox_FZ);
}
objects.push_back(anObj._retn());
}
myCurrObject = myObjects[i];
anObj = anOper->TranslateDXDYDZCopy(myObjects[i], dx, dy, dz);
if (!anObj->_is_nil()) {
- if(!IsPreview())
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ //if(!IsPreview())
+ // anObj->SetParameters(aParameters.join(":").toLatin1().constData());
objects.push_back(anObj._retn());
}
}
anObj = anOper->TranslateDXDYDZ(myObjects[i], dx, dy, dz);
if (!anObj->_is_nil()) {
if(!IsPreview()) {
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ //anObj->SetParameters(aParameters.join(":").toLatin1().constData());
updateAttributes(anObj, aParameters);
}
objects.push_back(anObj._retn());
anObj = anOper->TranslateVectorDistance(myObjects[i], myVector, aDistance, toCreateCopy);
if (!anObj->_is_nil()) {
if(!IsPreview()) {
- anObj->SetParameters(aParameters.join(":").toLatin1().constData());
+ //anObj->SetParameters(aParameters.join(":").toLatin1().constData());
if (!toCreateCopy)
updateAttributes(anObj, aParameters);
}