X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2FEntityGUI%2FEntityGUI_SketcherDlg.cxx;h=6749738fdec2ec85ebfbfd9ab742db57ca5a3be2;hb=f7d9823966bcf9898c561db3c641da816e9e9552;hp=fde880b435ff86b93d04d8b036b20a894c0f582e;hpb=7961b83044d771b15dbbe57ed71c20e67efec023;p=modules%2Fgeom.git diff --git a/src/EntityGUI/EntityGUI_SketcherDlg.cxx b/src/EntityGUI/EntityGUI_SketcherDlg.cxx index fde880b43..6749738fd 100644 --- a/src/EntityGUI/EntityGUI_SketcherDlg.cxx +++ b/src/EntityGUI/EntityGUI_SketcherDlg.cxx @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2014 CEA/DEN, EDF R&D, OPEN CASCADE +// Copyright (C) 2007-2015 CEA/DEN, EDF R&D, OPEN CASCADE // // Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN, // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS @@ -47,6 +47,7 @@ #include #include #include +#include "utilities.h" #include @@ -64,6 +65,7 @@ #include #include +#include "utilities.h" #include @@ -539,7 +541,7 @@ void EntityGUI_SketcherDlg::InitClick() Group4Spin->hide(); GroupRect->hide(); globalSelection(); // close local selection to clear it - localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX ); + localSelection( TopAbs_VERTEX ); } @@ -630,15 +632,14 @@ void EntityGUI_SketcherDlg::RectClicked() SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) ); GroupRect->show(); - + myX1=0; - myX2=10; - myY1=0; - myY2=10; - GroupRect->SpinBox_DX1->setValue(myX1); + myY1=0; GroupRect->SpinBox_DY1->setValue(myY1); + myX2=10; GroupRect->SpinBox_DX2->setValue(myX2); + myY2=10; GroupRect->SpinBox_DY2->setValue(myY2); resize( minimumSizeHint() ); @@ -1142,7 +1143,7 @@ void EntityGUI_SketcherDlg::ClickOnEnd() } QString Command = myCommand.join( "" ); - Sketcher_Profile aProfile = Sketcher_Profile( Command.toAscii() ); + Sketcher_Profile aProfile = Sketcher_Profile( Command.toLatin1() ); bool isDone = false; TopoDS_Shape myShape = aProfile.GetShape( &isDone ); if ( isDone ) { @@ -1570,7 +1571,7 @@ void EntityGUI_SketcherDlg::SetEditCurrentArgument() selButton->setDown(true); } globalSelection(); // close local selection to clear it - localSelection(GEOM::GEOM_Object::_nil(), myNeedType); + localSelection( myNeedType ); } @@ -2258,7 +2259,7 @@ QString EntityGUI_SketcherDlg::GetNewCommand( QString& theParameters ) + ":TT " + QString::number( myX2, Format, DigNum) + " " + QString::number( myY1, Format, DigNum) + ":WW"; - theParameters = myX1Str + ":" + myY1Str + ":" + myX2Str + ":" + myY2Str ; + theParameters = myX1Str + ":" + myY1Str + ":" + myX1Str + ":" + myY2Str + ":" + myX2Str + ":" + myY2Str + ":" + myX2Str + ":" + myY1Str; } return myNewCommand; } @@ -2340,12 +2341,12 @@ bool EntityGUI_SketcherDlg::execute( ObjectList& objects ) //Last Shape QString Command1 = myCommand.join( "" ); - Sketcher_Profile aProfile1( Command1.toAscii() ); + Sketcher_Profile aProfile1( Command1.toLatin1() ); myShape1 = aProfile1.GetShape(); //Current Shape QString Command2 = Command1 + GetNewCommand( aParameters ); - Sketcher_Profile aProfile2( Command2.toAscii() ); + Sketcher_Profile aProfile2( Command2.toLatin1() ); myShape2 = aProfile2.GetShape( &isDone, &error ); //Error Message