Implementation of the "21187: EDF 1137 GEOM: Performance issue when manipulating large models" issue.

This commit is contained in:
rnv 2011-03-23 10:18:35 +00:00
parent a4c7964a28
commit 46574ac4f4
60 changed files with 316 additions and 180 deletions

View File

@ -52,6 +52,7 @@
<parameter name="auto_create_base_objects" value="false" />
<parameter name="base_vectors_length" value="1" />
<parameter name="marker_scale" value="1" />
<parameter name="geom_preview" value="false" />
<!-- Input field precisions -->
<parameter name="def_precision" value="3" />
<parameter name="length_precision" value="6" />

View File

@ -217,6 +217,8 @@ void AdvancedGUI_PipeTShapeDlg::Init() {
CssAcceptable = "QDoubleSpinBox, QPushButton {background-color: rgb(85, 170, 127)}";
CssRefused = "QDoubleSpinBox, QPushButton {background-color: rgb(255, 0, 0)}";
showOnlyPreviewControl();
// Signal/slot connections
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));
connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));
@ -249,7 +251,7 @@ void AdvancedGUI_PipeTShapeDlg::Init() {
initName(tr("GEOM_PIPE_TSHAPE"));
updateTshapeScreenshotLabel();
DisplayPreview();
processPreview();
}
//=================================================================================
@ -271,7 +273,7 @@ void AdvancedGUI_PipeTShapeDlg::ApplyNewDimensions() {
MainTubeGroupParams->SpinBox_DZ->setToolTip("");
MainTubeGroupParams->SpinBox_DZ->setStyleSheet("background-color: rgb(255, 255, 255);");
CheckCompatiblePosition(myPoint1, myPoint2, myPoint3, 0.01);
DisplayPreview();
processPreview();
}
}
}
@ -285,7 +287,7 @@ void AdvancedGUI_PipeTShapeDlg::ApplyNewDimensions() {
IncidentTubeGroupParams->SpinBox_DZ->setToolTip("");
IncidentTubeGroupParams->SpinBox_DZ->setStyleSheet("background-color: rgb(255, 255, 255);");
CheckCompatiblePosition(myPoint1, myPoint2, myPoint3, 0.01);
DisplayPreview();
processPreview();
}
}
}
@ -369,7 +371,7 @@ void AdvancedGUI_PipeTShapeDlg::SetPosition(bool isChecked) {
disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
JunctionPointsSel->LineEdit4->setText("");
JunctionPointsSel->LineEdit5->setText("");
DisplayPreview();
processPreview();
}
}
@ -381,7 +383,7 @@ void AdvancedGUI_PipeTShapeDlg::ValueChangedInSpinBox(double newValue)
{
if (JunctionPointsSel->GroupBox1->isChecked() && myOkPoint1 && myOkPoint2 && myOkPoint3)
CheckCompatiblePosition(myPoint1, myPoint2, myPoint3, 0.01);
DisplayPreview();
processPreview();
}
//=================================================================================
@ -467,7 +469,7 @@ void AdvancedGUI_PipeTShapeDlg::SelectionIntoArgument() {
if (myOkPoint1 && myOkPoint2 && myOkPoint3) {
CheckCompatiblePosition(myPoint1, myPoint2, myPoint3, 0.01);
DisplayPreview();
processPreview();
}
// GEOM::GEOM_Object_var aSelectedObject = GEOMBase::ConvertIOinGEOMObject(aSelList.First());
@ -596,7 +598,7 @@ void AdvancedGUI_PipeTShapeDlg::ActivateThisDialog() {
// currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
if (myOkPoint1 && myOkPoint2 && myOkPoint3)
CheckCompatiblePosition(myPoint1, myPoint2, myPoint3, 0.01);
DisplayPreview();
processPreview();
}
//=================================================================================
@ -649,7 +651,7 @@ void AdvancedGUI_PipeTShapeDlg::ChamferOrFillet(bool) {
updateTshapeScreenshotLabel();
if (myOkPoint1 && myOkPoint2 && myOkPoint3)
CheckCompatiblePosition(myPoint1, myPoint2, myPoint3, 0.01);
DisplayPreview();
processPreview();
} else if (send == FilletGroupParams->GroupBox1) {
if (send->isChecked()) {
disconnect(ChamferGroupParams->GroupBox1, SIGNAL(toggled(bool)), this, 0);
@ -662,7 +664,7 @@ void AdvancedGUI_PipeTShapeDlg::ChamferOrFillet(bool) {
updateTshapeScreenshotLabel();
if (myOkPoint1 && myOkPoint2 && myOkPoint3)
CheckCompatiblePosition(myPoint1, myPoint2, myPoint3, 0.01);
DisplayPreview();
processPreview();
}
}
@ -973,3 +975,14 @@ void AdvancedGUI_PipeTShapeDlg::restoreSubShapes(SALOMEDS::Study_ptr theStudy, S
}
}
//=================================================================================
// function : processPreview()
// purpose : Display preview if CheckBoxPreview is checked
//=================================================================================
void AdvancedGUI_PipeTShapeDlg::processPreview() {
if(mainFrame()->CheckBoxPreview->isChecked())
DisplayPreview();
else
erasePreview(true);
}

View File

@ -83,6 +83,7 @@ private slots:
void DisplayPreview(const bool activate = false, const bool update = true,
const bool toRemoveFromEngine = true, const double lineWidth = -1,
const int displayMode = -1, const int color = -1);
virtual void processPreview();
void SetPosition(bool);
void ChamferOrFillet(bool);
void SetDoubleSpinBoxStep(double);

View File

@ -319,7 +319,7 @@ void BasicGUI_ArcDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
@ -416,7 +416,7 @@ void BasicGUI_ArcDlg::SetEditCurrentArgument()
myEditCurrentArgument->setFocus();
// SelectionIntoArgument();
send->setDown(true);
displayPreview();
displayPreview(true);
}
@ -592,7 +592,7 @@ void BasicGUI_ArcDlg::ConstructorsClicked( int constructorId )
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -601,7 +601,7 @@ void BasicGUI_ArcDlg::ConstructorsClicked( int constructorId )
//=================================================================================
void BasicGUI_ArcDlg::ReverseSense()
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -289,7 +289,7 @@ void BasicGUI_CircleDlg::ConstructorsClicked( int constructorId )
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged() ),
this, SLOT( SelectionIntoArgument() ) );
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -391,7 +391,7 @@ void BasicGUI_CircleDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
@ -476,7 +476,7 @@ void BasicGUI_CircleDlg::SetEditCurrentArgument()
myEditCurrentArgument->setFocus();
// SelectionIntoArgument();
send->setDown(true);
displayPreview();
displayPreview(true);
}
@ -520,7 +520,7 @@ void BasicGUI_CircleDlg::DeactivateActiveDialog()
//=================================================================================
void BasicGUI_CircleDlg::ValueChangedInSpinBox()
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -122,6 +122,8 @@ void BasicGUI_CurveDlg::Init()
globalSelection(); // close local contexts, if any
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
showOnlyPreviewControl();
/* signals and slots connections */
connect( myGeomGUI, SIGNAL( SignalDeactivateActiveDialog() ), this, SLOT( DeactivateActiveDialog( ) ) );
connect( myGeomGUI, SIGNAL( SignalCloseAllDialogs() ), this, SLOT( ClickOnCancel() ) );
@ -141,7 +143,7 @@ void BasicGUI_CurveDlg::Init()
initName( tr( "GEOM_CURVE" ) );
resize(100,100);
ConstructorsClicked( 0 );
ConstructorsClicked( 0 );
}
//=================================================================================
@ -197,7 +199,7 @@ void BasicGUI_CurveDlg::SetEditCurrentArgument()
//=================================================================================
void BasicGUI_CurveDlg::CheckButtonToggled()
{
displayPreview();
processPreview();
}
//=================================================================================
@ -263,7 +265,7 @@ void BasicGUI_CurveDlg::SelectionIntoArgument()
GroupPoints->LineEdit1->setText( QString::number( myPoints.count() ) + "_" + tr( "GEOM_POINT" ) + tr( "_S_" ) );
else
GroupPoints->LineEdit1->setText( "" );
displayPreview();
processPreview();
}

View File

@ -159,7 +159,7 @@ void BasicGUI_EllipseDlg::Init()
resize( minimumSizeHint() );
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -212,7 +212,7 @@ bool BasicGUI_EllipseDlg::ClickOnApply()
globalSelection(); // close local contexts, if any
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
displayPreview();
displayPreview(true);
return true;
}
@ -261,7 +261,7 @@ void BasicGUI_EllipseDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
@ -307,7 +307,7 @@ void BasicGUI_EllipseDlg::SetEditCurrentArgument()
myEditCurrentArgument->setFocus();
//SelectionIntoArgument();
send->setDown(true);
displayPreview();
displayPreview(true);
}
@ -361,7 +361,7 @@ void BasicGUI_EllipseDlg::enterEvent( QEvent* )
//=================================================================================
void BasicGUI_EllipseDlg::ValueChangedInSpinBox( double newValue )
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -244,7 +244,7 @@ void BasicGUI_LineDlg::SelectionIntoArgument()
else if (myEditCurrentArgument == GroupPoints->LineEdit2) myPoint2.nullify();
else if (myEditCurrentArgument == GroupFaces->LineEdit1) myFace1.nullify();
else if (myEditCurrentArgument == GroupFaces->LineEdit2) myFace2.nullify();
displayPreview();
displayPreview(true);
return;
}
@ -278,7 +278,7 @@ void BasicGUI_LineDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -322,7 +322,7 @@ void BasicGUI_LineDlg::SetEditCurrentArgument()
myEditCurrentArgument->setFocus();
// SelectionIntoArgument();
send->setDown(true);
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -284,7 +284,7 @@ void BasicGUI_MarkerDlg::ConstructorsClicked( int constructorId )
}
}
displayPreview();
displayPreview(true);
qApp->processEvents();
updateGeometry();
@ -351,7 +351,7 @@ void BasicGUI_MarkerDlg::onSelectionDone0()
myData[ DY2 ]->setValue( aYDir.Y() );
myData[ DZ2 ]->setValue( aYDir.Z() );
}
displayPreview();
displayPreview(true);
return;
}
aSelectedObject = getSelected( TopAbs_VERTEX );
@ -360,7 +360,7 @@ void BasicGUI_MarkerDlg::onSelectionDone0()
myData[ X ]->setValue( aPnt.X() );
myData[ Y ]->setValue( aPnt.Y() );
myData[ Z ]->setValue( aPnt.Z() );
displayPreview();
displayPreview(true);
return;
}
}
@ -423,7 +423,7 @@ void BasicGUI_MarkerDlg::onSelectionDone()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -617,7 +617,7 @@ void BasicGUI_MarkerDlg::addSubshapesToStudy()
//=================================================================================
void BasicGUI_MarkerDlg::onValueChanged( double )
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -377,7 +377,7 @@ void BasicGUI_PlaneDlg::ConstructorsClicked( int constructorId )
myEditCurrentArgument->setFocus();
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
this, SLOT( SelectionIntoArgument() ) );
displayPreview();
displayPreview(true);
}
@ -420,7 +420,7 @@ void BasicGUI_PlaneDlg::GroupClicked()
myOriginType = 2;
else if ( send == GroupLCS->RadioButton3 )
myOriginType = 3;
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -445,7 +445,7 @@ void BasicGUI_PlaneDlg::SelectionIntoArgument()
else if ( myEditCurrentArgument == Group2Vec->LineEdit1 ) myVec1.nullify();
else if ( myEditCurrentArgument == Group2Vec->LineEdit2 ) myVec2.nullify();
else if ( myEditCurrentArgument == GroupLCS->LineEdit1 ) myLCS.nullify();
displayPreview();
displayPreview(true);
return;
}
@ -502,7 +502,7 @@ void BasicGUI_PlaneDlg::SelectionIntoArgument()
myLCS = aSelectedObject;
}
displayPreview();
displayPreview(true);
}
@ -590,7 +590,7 @@ void BasicGUI_PlaneDlg::SetEditCurrentArgument()
// SelectionIntoArgument();
myEditCurrentArgument->setFocus();
send->setDown(true);
displayPreview();
displayPreview(true);
}
@ -634,7 +634,7 @@ void BasicGUI_PlaneDlg::enterEvent( QEvent* )
//=================================================================================
void BasicGUI_PlaneDlg::ValueChangedInSpinBox( double newValue )
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -541,8 +541,8 @@ void BasicGUI_PointDlg::SelectionIntoArgument()
}
myBusy = false;
}
displayPreview();
displayPreview(true);
}
@ -638,7 +638,7 @@ void BasicGUI_PointDlg::DeactivateActiveDialog()
//=================================================================================
void BasicGUI_PointDlg::ValueChangedInSpinBox(double newValue)
{
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -647,7 +647,7 @@ void BasicGUI_PointDlg::ValueChangedInSpinBox(double newValue)
//=================================================================================
void BasicGUI_PointDlg::CheckBoxClicked( int State )
{
displayPreview();
displayPreview(true);
}
@ -692,7 +692,7 @@ void BasicGUI_PointDlg::OnPointSelected( const gp_Pnt& thePnt )
GroupXYZ->SpinBox_DY->setValue( thePnt.Y() );
GroupXYZ->SpinBox_DZ->setValue( thePnt.Z() );
displayPreview();
displayPreview(true);
}
}
@ -919,7 +919,7 @@ void BasicGUI_PointDlg::addSubshapesToStudy()
void BasicGUI_PointDlg::ClickParamCoord( int id )
{
updateParamCoord( true );
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -230,7 +230,7 @@ void BasicGUI_VectorDlg::ConstructorsClicked( int constructorId )
resize( minimumSizeHint() );
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
@ -299,7 +299,7 @@ void BasicGUI_VectorDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -326,7 +326,7 @@ void BasicGUI_VectorDlg::SetEditCurrentArgument()
globalSelection(); // close local selection to clear it
localSelection( GEOM::GEOM_Object::_nil(), TopAbs_VERTEX );
send->setDown(true);
displayPreview();
displayPreview(true);
}
@ -368,7 +368,7 @@ void BasicGUI_VectorDlg::enterEvent( QEvent* )
//=================================================================================
void BasicGUI_VectorDlg::ValueChangedInSpinBox( double newValue )
{
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -385,7 +385,7 @@ void BasicGUI_VectorDlg::ReverseVector( int state )
GroupDimensions->SpinBox_DY->setValue( dy );
GroupDimensions->SpinBox_DZ->setValue( dz );
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -402,7 +402,7 @@ void BasicGUI_WorkingPlaneDlg::SetEditCurrentArgument()
myEditCurrentArgument->setFocus();
// SelectionIntoArgument();
send->setDown(true);
displayPreview();
displayPreview(true);
}

View File

@ -307,7 +307,7 @@ void BlocksGUI_BlockDlg::SelectionIntoArgument()
myEditCurrentArgument->setText( "" );
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -402,7 +402,7 @@ void BlocksGUI_BlockDlg::ActivateThisDialog()
localSelection(GEOM::GEOM_Object::_nil(), TopAbs_FACE); //Select Faces on All Shapes
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
this, SLOT(SelectionIntoArgument()));
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -328,7 +328,7 @@ void BlocksGUI_QuadFaceDlg::SelectionIntoArgument()
myEditCurrentArgument->setText( "" );
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -411,7 +411,7 @@ void BlocksGUI_QuadFaceDlg::ActivateThisDialog()
activateSelection();
// ??
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -118,6 +118,8 @@ void BlocksGUI_TrsfDlg::Init()
initSpinBox(anIter.value(), 1, 999, SpecificStep);
}
showOnlyPreviewControl();
// signals and slots connections
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));
connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));
@ -270,7 +272,7 @@ void BlocksGUI_TrsfDlg::SelectionIntoArgument()
}
myEditCurrentArgument->setText(aName);
myFaces[aCurrFocus] = anIndex;
displayPreview();
processPreview();
}
switch (aCurrFocus) {
@ -388,7 +390,7 @@ void BlocksGUI_TrsfDlg::ActivateThisDialog()
activateSelection();
// ??
displayPreview();
processPreview();
}
//=================================================================================
@ -407,7 +409,7 @@ void BlocksGUI_TrsfDlg::enterEvent (QEvent*)
//=================================================================================
void BlocksGUI_TrsfDlg::ValueChangedInSpinBox(int)
{
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -263,7 +263,7 @@ void BooleanGUI_Dialog::ActivateThisDialog()
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
this, SLOT( SelectionIntoArgument() ) );
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -102,6 +102,7 @@ void BuildGUI_CompoundDlg::Init()
myShapes.clear();
mainFrame()->GroupBoxPublish->show();
mainFrame()->CheckBoxPreview->hide();
/* signals and slots connections */
connect( buttonOk(), SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) );

View File

@ -239,7 +239,7 @@ void BuildGUI_EdgeDlg::SelectionIntoArgument()
if (myEditCurrentArgument == GroupPoints->LineEdit1) myPoint1.nullify();
else if (myEditCurrentArgument == GroupPoints->LineEdit2) myPoint2.nullify();
else if (myEditCurrentArgument == GroupWire->LineEdit1) myWire.nullify();
displayPreview();
displayPreview(true);
return;
}
@ -268,7 +268,7 @@ void BuildGUI_EdgeDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -297,7 +297,7 @@ void BuildGUI_EdgeDlg::SetEditCurrentArgument()
myEditCurrentArgument->setEnabled(true);
myEditCurrentArgument->setFocus();
send->setDown(true);
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -136,6 +136,13 @@
</property>
</widget>
</item>
<item>
<widget class="QCheckBox" name="CheckBoxPreview" >
<property name="text" >
<string/>
</property>
</widget>
</item>
</layout>
</widget>
</item>
@ -218,6 +225,7 @@
<tabstops>
<tabstop>CheckBoxRestoreSS</tabstop>
<tabstop>CheckBoxAddPrefix</tabstop>
<tabstop>CheckBoxPreview</tabstop>
<tabstop>buttonOk</tabstop>
<tabstop>buttonApply</tabstop>
<tabstop>buttonCancel</tabstop>

View File

@ -248,13 +248,19 @@ void GEOMBase_Helper::redisplay( GEOM::GEOM_Object_ptr object,
// Function : displayPreview
// Purpose : Method for displaying preview based on execute() results
//================================================================
void GEOMBase_Helper::displayPreview( const bool activate,
void GEOMBase_Helper::displayPreview( const bool display,
const bool activate,
const bool update,
const bool toRemoveFromEngine,
const double lineWidth,
const int displayMode,
const int color )
{
if(!display) {
erasePreview( update );
return;
}
isPreview = true;
QString msg;
if ( !isValid( msg ) )

View File

@ -72,7 +72,8 @@ protected:
void redisplay ( const ObjectList&, const bool = true, const bool = true );
void redisplay ( GEOM::GEOM_Object_ptr, const bool = true, const bool = true );
virtual void displayPreview ( const bool activate = false,
virtual void displayPreview ( const bool display,
const bool activate = false,
const bool update = true,
const bool toRemoveFromEngine = true,
const double lineWidth = -1,

View File

@ -73,6 +73,7 @@ GEOMBase_Skeleton::GEOMBase_Skeleton( GeometryGUI* theGeometryGUI, QWidget* pare
myMainFrame->GroupBoxPublish->setTitle( tr( "GEOM_PUBLISH_RESULT_GRP" ) );
myMainFrame->CheckBoxRestoreSS->setText( tr( "GEOM_RESTORE_SUB_SHAPES" ) );
myMainFrame->CheckBoxAddPrefix->setText( tr( "GEOM_RSS_ADD_FREFIX" ) );
myMainFrame->CheckBoxPreview->setText( tr("GEOM_PREVIEW") );
buttonCancel()->setText( tr( "GEOM_BUT_CLOSE" ) );
buttonOk()->setText( tr( "GEOM_BUT_APPLY_AND_CLOSE" ) );
@ -125,6 +126,8 @@ void GEOMBase_Skeleton::Init()
// connect help button on a private slot that displays help information
connect( buttonHelp(), SIGNAL( clicked() ), this, SLOT( ClickOnHelp() ) );
connect( myMainFrame->CheckBoxPreview, SIGNAL(toggled(bool)), this, SLOT(processPreview()) );
/* displays Dialog */
myMainFrame->RadioButton1->setChecked( true );
myMainFrame->RadioButton4->hide();
@ -132,6 +135,11 @@ void GEOMBase_Skeleton::Init()
myMainFrame->CheckBoxRestoreSS->setChecked( false );
myMainFrame->CheckBoxAddPrefix->setChecked( true );
SUIT_ResourceMgr* resMgr = SUIT_Session::session()->resourceMgr();
bool aPrv = (resMgr == 0) ? false : resMgr->booleanValue( "Geometry", "geom_preview", false );
myMainFrame->CheckBoxPreview->setChecked( aPrv );
myMainFrame->GroupBoxPublish->hide();
}
@ -409,3 +417,22 @@ void GEOMBase_Skeleton::keyPressEvent( QKeyEvent* e )
ClickOnHelp();
}
}
//=================================================================================
// function : showOnlyPreviewControl()
// purpose : display only CheckBoxPreview check box,
// hide CheckBoxRestoreSS and CheckBoxAddPrefix
//=================================================================================
void GEOMBase_Skeleton::showOnlyPreviewControl(){
mainFrame()->GroupBoxPublish->show();
mainFrame()->CheckBoxRestoreSS->hide();
mainFrame()->CheckBoxAddPrefix->hide();
}
//=================================================================================
// function : processPreview()
// purpose : Display preview if CheckBoxPreview is checked
//=================================================================================
void GEOMBase_Skeleton::processPreview() {
displayPreview(mainFrame()->CheckBoxPreview->isChecked());
}

View File

@ -86,6 +86,8 @@ protected:
*/
void unsetConstructorId();
void showOnlyPreviewControl();
void setHelpFileName( const QString& );
DlgRef_Skeleton* mainFrame();
@ -105,6 +107,7 @@ protected:
protected slots:
virtual void ClickOnCancel();
virtual void processPreview();
void LineEditReturnPressed();
void DeactivateActiveDialog();
void ActivateThisDialog();

View File

@ -2721,6 +2721,10 @@ Please, select face, shell or solid and try again</translation>
<source>PREF_GROUP_ORIGIN_AND_BASE_VECTORS</source>
<translation>Origin and base vectors</translation>
</message>
<message>
<source>PREF_GROUP_OPERATIONS</source>
<translation>Operations</translation>
</message>
<message>
<source>PREF_GROUP_GENERAL</source>
<translation>General</translation>
@ -4117,6 +4121,10 @@ Please, select face, shell or solid and try again</translation>
<source>GEOM_RSS_ADD_FREFIX</source>
<translation>Add prefix to names of restored subshapes</translation>
</message>
<message>
<source>GEOM_PREVIEW</source>
<translation>Preview</translation>
</message>
<message>
<source>GEOM_ALL_IMPORT_FILES</source>
<translation>All supported formats ( %1 )</translation>

View File

@ -1196,7 +1196,6 @@ bool GeometryGUI::activateModule( SUIT_Study* study )
if ( !res )
return false;
setMenuShown( true );
setToolShown( true );
@ -1637,6 +1636,13 @@ void GeometryGUI::createPreferences()
addPreference( tr( "PREF_AUTO_CREATE" ), originGroup,
LightApp_Preferences::Bool, "Geometry", "auto_create_base_objects" );
int operationsGroup = addPreference( tr( "PREF_GROUP_OPERATIONS" ), tabId );
setPreferenceProperty( operationsGroup, "columns", 2 );
addPreference( tr( "GEOM_PREVIEW" ), operationsGroup,
LightApp_Preferences::Bool, "Geometry", "geom_preview" );
}
void GeometryGUI::preferencesChanged( const QString& section, const QString& param )

View File

@ -126,6 +126,8 @@ void GenerationGUI_FillingDlg::Init()
GroupPoints->ComboBox1->addItem(tr("GEOM_FILLING_USEORI"));
GroupPoints->ComboBox1->addItem(tr("GEOM_FILLING_AUTO"));
showOnlyPreviewControl();
/* signals and slots connections */
connect( buttonOk(), SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) );
connect( buttonApply(), SIGNAL( clicked() ), this, SLOT( ClickOnApply() ) );
@ -211,7 +213,7 @@ void GenerationGUI_FillingDlg::SelectionIntoArgument()
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -242,7 +244,7 @@ void GenerationGUI_FillingDlg::ActivateThisDialog()
connect( ( (SalomeApp_Application*)( SUIT_Session::session()->activeApplication() ) )->selectionMgr(),
SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
globalSelection( GEOM_COMPOUND );
displayPreview();
processPreview();
}
@ -263,7 +265,7 @@ void GenerationGUI_FillingDlg::enterEvent( QEvent* )
//=================================================================================
void GenerationGUI_FillingDlg::ValueChangedInSpinBox( double newValue )
{
displayPreview();
processPreview();
}
//=================================================================================
@ -272,7 +274,7 @@ void GenerationGUI_FillingDlg::ValueChangedInSpinBox( double newValue )
//=================================================================================
void GenerationGUI_FillingDlg::MethodChanged()
{
displayPreview();
processPreview();
}
//=================================================================================
@ -281,7 +283,7 @@ void GenerationGUI_FillingDlg::MethodChanged()
//=================================================================================
void GenerationGUI_FillingDlg::ApproxChanged()
{
displayPreview();
processPreview();
}

View File

@ -119,6 +119,8 @@ void GenerationGUI_PipeDlg::Init()
GroupPoints->CheckButton1->setEnabled(false);
showOnlyPreviewControl();
// signals and slots connections
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));
connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));
@ -172,7 +174,7 @@ void GenerationGUI_PipeDlg::ConstructorsClicked( int constructorId )
resize(100,100);
SelectionIntoArgument();
displayPreview();
processPreview();
}
//=================================================================================
@ -195,7 +197,7 @@ void GenerationGUI_PipeDlg::SelectionTypeButtonClicked()
myEditCurrentArgument->setText("");
myPath.nullify();
}
displayPreview();
processPreview();
}
//=================================================================================
@ -275,7 +277,7 @@ void GenerationGUI_PipeDlg::SelectionIntoArgument()
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -327,7 +329,7 @@ void GenerationGUI_PipeDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -195,6 +195,8 @@ void GenerationGUI_PrismDlg::Init()
myPoint2.nullify();
myVec.nullify();
showOnlyPreviewControl();
// signals and slots connections
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));
connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));
@ -290,7 +292,7 @@ void GenerationGUI_PrismDlg::ConstructorsClicked (int constructorId)
resize(minimumSizeHint());
SelectionIntoArgument();
displayPreview();
processPreview();
}
//=================================================================================
@ -382,7 +384,7 @@ void GenerationGUI_PrismDlg::SelectionIntoArgument()
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -442,7 +444,7 @@ void GenerationGUI_PrismDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -475,7 +477,7 @@ void GenerationGUI_PrismDlg::enterEvent (QEvent*)
//=================================================================================
void GenerationGUI_PrismDlg::ValueChangedInSpinBox()
{
displayPreview();
processPreview();
}
//=================================================================================
@ -550,7 +552,7 @@ void GenerationGUI_PrismDlg::onBothway()
GroupDXDYDZ->SpinBox_SC->setEnabled(!GroupDXDYDZ->CheckBox1->isChecked() &&
GroupDXDYDZ->CheckBox2->isChecked()); // scale factor
displayPreview();
processPreview();
}
//=================================================================================
@ -568,7 +570,7 @@ void GenerationGUI_PrismDlg::onScalePrism()
GroupDXDYDZ->TextLabel5->setEnabled(GroupDXDYDZ->CheckBox2->isChecked());
GroupDXDYDZ->SpinBox_SC->setEnabled(GroupDXDYDZ->CheckBox2->isChecked());
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -122,6 +122,8 @@ void GenerationGUI_RevolDlg::Init()
myBaseObjects.clear();
myAxis.nullify();
showOnlyPreviewControl();
// signals and slots connections
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));
connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));
@ -209,7 +211,7 @@ void GenerationGUI_RevolDlg::SelectionIntoArgument()
GroupPoints->PushButton1->click();
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -243,7 +245,7 @@ void GenerationGUI_RevolDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -256,7 +258,7 @@ void GenerationGUI_RevolDlg::ActivateThisDialog()
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
this, SLOT( SelectionIntoArgument() ) );
displayPreview();
processPreview();
}
//=================================================================================
@ -275,7 +277,7 @@ void GenerationGUI_RevolDlg::enterEvent (QEvent*)
//=================================================================================
void GenerationGUI_RevolDlg::ValueChangedInSpinBox()
{
displayPreview();
processPreview();
}
//=================================================================================
@ -350,7 +352,7 @@ void GenerationGUI_RevolDlg::onReverse()
void GenerationGUI_RevolDlg::onBothway()
{
GroupPoints->CheckButton2->setEnabled(!GroupPoints->CheckButton1->isChecked());
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -180,7 +180,7 @@ void MeasureGUI_CenterMassDlg::SelectionIntoArgument()
myObj = aSelectedObject;
processObject();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -221,7 +221,7 @@ void MeasureGUI_CenterMassDlg::ActivateThisDialog()
SIGNAL(currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
globalSelection();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -250,7 +250,7 @@ void MeasureGUI_CenterMassDlg::processObject()
myGrp->LineEdit3->setText( DlgRef::PrintDoubleValue( y, aPrecision ) );
myGrp->LineEdit4->setText( DlgRef::PrintDoubleValue( z, aPrecision ) );
displayPreview();
displayPreview(true);
}
}

View File

@ -188,7 +188,7 @@ void MeasureGUI_CheckCompoundOfBlocksDlg::SelectionIntoArgument()
myObj = aSelectedObject;
myGrp->LineEdit1->setText( GEOMBase::GetName( myObj ) );
processObject();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -228,7 +228,7 @@ void MeasureGUI_CheckCompoundOfBlocksDlg::ActivateThisDialog()
connect( aSel, SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
activateSelection();
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -246,7 +246,7 @@ void MeasureGUI_NormaleDlg::SelectionIntoArgument()
GroupArgs->PushButton1->click();
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -286,7 +286,7 @@ void MeasureGUI_NormaleDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -313,7 +313,7 @@ void MeasureGUI_NormaleDlg::ActivateThisDialog()
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
this, SLOT( SelectionIntoArgument() ) );
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -111,6 +111,8 @@ void OperationGUI_ArchimedeDlg::Init()
initSpinBox( GroupPoints->SpinBox_DY, 0.001, COORD_MAX, SpecificStep1, "density_precision" );
initSpinBox( GroupPoints->SpinBox_DZ, 0.001, COORD_MAX, SpecificStep2, "parametric_precision" );
showOnlyPreviewControl();
GroupPoints->SpinBox_DX->setValue( 100.0 );
GroupPoints->SpinBox_DY->setValue( 1.0 );
GroupPoints->SpinBox_DZ->setValue( 0.01 );
@ -125,6 +127,11 @@ void OperationGUI_ArchimedeDlg::Init()
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
this, SLOT( SelectionIntoArgument() ) );
connect(GroupPoints->SpinBox_DX, SIGNAL(valueChanged( double )), this, SLOT(ValueChangedInSpinBox(double)));
connect(GroupPoints->SpinBox_DY, SIGNAL(valueChanged( double )), this, SLOT(ValueChangedInSpinBox(double)));
connect(GroupPoints->SpinBox_DZ, SIGNAL(valueChanged( double )), this, SLOT(ValueChangedInSpinBox(double)));
initName( tr( "GEOM_ARCHIMEDE" ) );
@ -194,8 +201,8 @@ void OperationGUI_ArchimedeDlg::SelectionIntoArgument()
myShape = GEOM::GEOM_Object::_nil();
return;
}
myEditCurrentArgument->setText(GEOMBase::GetName(myShape));
processPreview();
}
//=================================================================================
@ -223,6 +230,7 @@ void OperationGUI_ArchimedeDlg::ActivateThisDialog()
globalSelection( GEOM_ALLSHAPES );
connect( myGeomGUI->getApp()->selectionMgr(),
SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
processPreview();
}
@ -288,3 +296,12 @@ bool OperationGUI_ArchimedeDlg::execute( ObjectList& objects )
return true;
}
//=================================================================================
// function : ValueChangedInSpinBox()
// purpose :
//=================================================================================
void OperationGUI_ArchimedeDlg::ValueChangedInSpinBox(double newValue)
{
processPreview();
}

View File

@ -65,6 +65,7 @@ private slots:
void LineEditReturnPressed();
void SelectionIntoArgument();
void SetDoubleSpinBoxStep( double );
void ValueChangedInSpinBox( double );
};
#endif // OPERATIONGUI_ARCHIMEDEDLG_H

View File

@ -193,6 +193,8 @@ void OperationGUI_ChamferDlg::Init()
myFace[ Face1 ] = -1;
myFace[ Face2 ] = -1;
showOnlyPreviewControl();
// signals and slots connections
// main buttons
@ -354,7 +356,7 @@ void OperationGUI_ChamferDlg::ConstructorsClicked (int constructorId)
myEditCurrentArgument->setText("");
}
displayPreview();
processPreview();
}
qApp->processEvents();
@ -421,7 +423,7 @@ void OperationGUI_ChamferDlg::SelectionIntoArgument()
if ( !anObj->_is_nil() ) {
myShape = anObj;
myEditCurrentArgument->setText(GEOMBase::GetName(anObj));
displayPreview();
processPreview();
}
}
@ -444,7 +446,7 @@ void OperationGUI_ChamferDlg::SelectionIntoArgument()
QString aFaceName = QString(GEOMBase::GetName(anObj)) + ":%1";
myEditCurrentArgument->setText(aFaceName.arg(anIndex));
myFace[ aCurrFocus ] = anIndex;
displayPreview();
processPreview();
}
}
}
@ -479,7 +481,7 @@ void OperationGUI_ChamferDlg::SelectionIntoArgument()
else if (aConstructorId == 3)
myEdges = anIndexes;
displayPreview();
processPreview();
}
}
}
@ -567,7 +569,7 @@ void OperationGUI_ChamferDlg::SetEditCurrentArgument()
activateSelection();
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -615,7 +617,7 @@ void OperationGUI_ChamferDlg::enterEvent (QEvent*)
//=================================================================================
void OperationGUI_ChamferDlg::ValueChangedInSpinBox (double)
{
displayPreview();
processPreview();
}
//=================================================================================
@ -960,5 +962,5 @@ void OperationGUI_ChamferDlg::RadioButtonPressed()
myRadioButton[ RadioButton41 ]->blockSignals(false);
myRadioButton[ RadioButton42 ]->blockSignals(false);
displayPreview();
processPreview();
}

View File

@ -120,6 +120,8 @@ void OperationGUI_Fillet1d2dDlg::Init()
myVertexes.Clear();
showOnlyPreviewControl();
// signals and slots connections
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk() ));
@ -221,7 +223,7 @@ void OperationGUI_Fillet1d2dDlg::SelectionIntoArgument()
myShape = anObj;
myEditCurrentArgument->setText(aName
);
displayPreview();
processPreview();
}
}
} else if (myEditCurrentArgument == GroupVertexes->LineEdit2) {
@ -251,7 +253,7 @@ void OperationGUI_Fillet1d2dDlg::SelectionIntoArgument()
}
}
if ( isPreview )
displayPreview();
processPreview();
}
if (myEditCurrentArgument == GroupVertexes->LineEdit1) {
@ -288,7 +290,7 @@ void OperationGUI_Fillet1d2dDlg::SetEditCurrentArgument()
activateSelection();
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -334,7 +336,7 @@ void OperationGUI_Fillet1d2dDlg::enterEvent (QEvent*)
//=================================================================================
void OperationGUI_Fillet1d2dDlg::ValueChangedInSpinBox (double)
{
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -160,6 +160,8 @@ void OperationGUI_FilletDlg::Init()
myFaces.Clear();
myEdges.Clear();
showOnlyPreviewControl();
// signals and slots connections
// main buttons
@ -292,7 +294,7 @@ void OperationGUI_FilletDlg::ConstructorsClicked (int constructorId)
else
myEditCurrentArgument->setText("");
displayPreview();
processPreview();
}
qApp->processEvents();
@ -351,7 +353,7 @@ void OperationGUI_FilletDlg::SelectionIntoArgument()
if ( !anObj->_is_nil() ) {
myShape = anObj;
myEditCurrentArgument->setText(GEOMBase::GetName(anObj));
displayPreview();
processPreview();
}
}
@ -389,7 +391,7 @@ void OperationGUI_FilletDlg::SelectionIntoArgument()
else
myFaces = anIndexes;
displayPreview();
processPreview();
}
}
}
@ -476,7 +478,7 @@ void OperationGUI_FilletDlg::SetEditCurrentArgument()
activateSelection();
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -528,7 +530,7 @@ void OperationGUI_FilletDlg::enterEvent (QEvent*)
//=================================================================================
void OperationGUI_FilletDlg::ValueChangedInSpinBox (double)
{
displayPreview();
processPreview();
}
//=================================================================================
@ -749,5 +751,5 @@ void OperationGUI_FilletDlg::RadioButtonClicked()
Group3->RadioButton1->blockSignals(false);
Group3->RadioButton2->blockSignals(false);
displayPreview();
processPreview();
}

View File

@ -114,6 +114,8 @@ void OperationGUI_GetShapesOnShapeDlg::Init()
GroupPoints->LineEdit2->clear();
myObject1 = myObject2 = GEOM::GEOM_Object::_nil();
showOnlyPreviewControl();
// signals and slots connections
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));
connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));
@ -211,6 +213,7 @@ void OperationGUI_GetShapesOnShapeDlg::SelectionIntoArgument()
}
}
}
processPreview();
}
//=================================================================================
@ -265,6 +268,7 @@ void OperationGUI_GetShapesOnShapeDlg::ActivateThisDialog()
globalSelection(GEOM_ALLSHAPES);
connect( myGeomGUI->getApp()->selectionMgr(), SIGNAL( currentSelectionChanged() ),
this, SLOT( SelectionIntoArgument() ) );
processPreview();
}
//=================================================================================
@ -346,4 +350,5 @@ void OperationGUI_GetShapesOnShapeDlg::ComboTextChanged()
{
// VRS ???? What is it for ??? commented for a while...
//bool IsEnabled = GroupPoints->ComboBox1->currentIndex() < 3;
processPreview();
}

View File

@ -114,6 +114,8 @@ void OperationGUI_GetSharedShapesDlg::Init()
GroupPoints->ComboBox1->setCurrentIndex(0);
showOnlyPreviewControl();
/* signals and slots connections */
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));
connect(buttonApply(), SIGNAL(clicked()), this, SLOT(ClickOnApply()));
@ -212,6 +214,7 @@ void OperationGUI_GetSharedShapesDlg::SelectionIntoArgument()
return;
myEditCurrentArgument->setText(aString);
processPreview();
}
//=================================================================================
@ -245,6 +248,7 @@ void OperationGUI_GetSharedShapesDlg::ActivateThisDialog()
SIGNAL(currentSelectionChanged()), this, SLOT(SelectionIntoArgument()));
ConstructorsClicked(getConstructorId());
processPreview();
}
//=================================================================================
@ -265,6 +269,7 @@ void OperationGUI_GetSharedShapesDlg::ComboTextChanged()
{
//initName(getNewObjectName());
initName(getPrefixByType());
processPreview();
}
//=================================================================================

View File

@ -151,6 +151,9 @@ void OperationGUI_PartitionDlg::Init()
connect( myGeomGUI->getApp()->selectionMgr(),
SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
connect( GroupPoints->CheckButton1, SIGNAL(toggled(bool)), this, SLOT(processPreview()) );
connect( GroupPoints->CheckButton2, SIGNAL(toggled(bool)), this, SLOT(processPreview()) );
initName( tr( "GEOM_PARTITION" ) );
@ -318,8 +321,9 @@ void OperationGUI_PartitionDlg::SelectionIntoArgument()
}
}
}
myEditCurrentArgument->setText( aString );
processPreview();
}
@ -352,6 +356,7 @@ void OperationGUI_PartitionDlg::SetEditCurrentArgument()
myEditCurrentArgument->setFocus();
SelectionIntoArgument();
send->setDown(true);
processPreview();
}
@ -382,6 +387,7 @@ void OperationGUI_PartitionDlg::ActivateThisDialog()
SIGNAL( currentSelectionChanged() ), this, SLOT( SelectionIntoArgument() ) );
ConstructorsClicked( getConstructorId() );
processPreview();
}
@ -496,6 +502,7 @@ void OperationGUI_PartitionDlg::ComboTextChanged()
//GroupPoints->TextLabel5->setEnabled(IsEnabled);
//GroupPoints->PushButton3->setEnabled(IsEnabled);
//GroupPoints->PushButton4->setEnabled(IsEnabled);
processPreview();
}
//=================================================================================

View File

@ -184,7 +184,7 @@ void PrimitiveGUI_BoxDlg::ConstructorsClicked (int constructorId)
disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
globalSelection(); // close local contexts, if any
displayPreview();
displayPreview(true);
break;
}
}
@ -194,7 +194,7 @@ void PrimitiveGUI_BoxDlg::ConstructorsClicked (int constructorId)
resize(minimumSizeHint());
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -269,7 +269,7 @@ void PrimitiveGUI_BoxDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -311,7 +311,7 @@ void PrimitiveGUI_BoxDlg::SetEditCurrentArgument()
this, SLOT(SelectionIntoArgument()));
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -326,7 +326,7 @@ void PrimitiveGUI_BoxDlg::ActivateThisDialog()
connect(myGeomGUI->getApp()->selectionMgr(), SIGNAL(currentSelectionChanged()),
this, SLOT(SelectionIntoArgument()));
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -345,7 +345,7 @@ void PrimitiveGUI_BoxDlg::enterEvent (QEvent*)
//=================================================================================
void PrimitiveGUI_BoxDlg::ValueChangedInSpinBox()
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -200,7 +200,7 @@ void PrimitiveGUI_ConeDlg::ConstructorsClicked (int constructorId)
disconnect(myGeomGUI->getApp()->selectionMgr(), 0, this, 0);
globalSelection(); // close local contexts, if any
displayPreview();
displayPreview(true);
break;
}
}
@ -210,7 +210,7 @@ void PrimitiveGUI_ConeDlg::ConstructorsClicked (int constructorId)
resize(minimumSizeHint());
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -286,7 +286,7 @@ void PrimitiveGUI_ConeDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -326,7 +326,7 @@ void PrimitiveGUI_ConeDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -359,7 +359,7 @@ void PrimitiveGUI_ConeDlg::enterEvent (QEvent*)
//=================================================================================
void PrimitiveGUI_ConeDlg::ValueChangedInSpinBox()
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -202,7 +202,7 @@ void PrimitiveGUI_CylinderDlg::ConstructorsClicked (int constructorId)
resize(minimumSizeHint());
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -280,7 +280,7 @@ void PrimitiveGUI_CylinderDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -320,7 +320,7 @@ void PrimitiveGUI_CylinderDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -353,7 +353,7 @@ void PrimitiveGUI_CylinderDlg::enterEvent (QEvent*)
//=================================================================================
void PrimitiveGUI_CylinderDlg::ValueChangedInSpinBox()
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -201,7 +201,7 @@ void PrimitiveGUI_DiskDlg::RadioButtonClicked()
myOrientationType = 2;
else if (GroupOrientation->RadioButton3->isChecked())
myOrientationType = 3;
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -251,7 +251,7 @@ void PrimitiveGUI_DiskDlg::ConstructorsClicked (int constructorId)
resize(minimumSizeHint());
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -345,7 +345,7 @@ void PrimitiveGUI_DiskDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -412,7 +412,7 @@ void PrimitiveGUI_DiskDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -444,7 +444,7 @@ void PrimitiveGUI_DiskDlg::enterEvent (QEvent*)
//=================================================================================
void PrimitiveGUI_DiskDlg::ValueChangedInSpinBox()
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -198,7 +198,7 @@ void PrimitiveGUI_FaceDlg::SetDoubleSpinBoxStep( double step )
//=================================================================================
void PrimitiveGUI_FaceDlg::ValueChangedInSpinBox( double newValue )
{
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -213,7 +213,7 @@ void PrimitiveGUI_FaceDlg::RadioButtonClicked()
myOrientationType = 2;
else if ( GroupOrientation->RadioButton3->isChecked() )
myOrientationType = 3;
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -306,7 +306,7 @@ void PrimitiveGUI_FaceDlg::ConstructorsClicked( int constructorId )
updateGeometry();
resize( minimumSizeHint() );
SelectionIntoArgument();
//displayPreview();
//displayPreview(true);
}
//=================================================================================
@ -316,7 +316,7 @@ void PrimitiveGUI_FaceDlg::ConstructorsClicked( int constructorId )
void PrimitiveGUI_FaceDlg::SelectionIntoArgument()
{
if (getConstructorId() == 0) {
displayPreview();
displayPreview(true);
return;
}
@ -345,7 +345,7 @@ void PrimitiveGUI_FaceDlg::SelectionIntoArgument()
myFace = aSelectedObject;
}
displayPreview();
displayPreview(true);
}

View File

@ -194,7 +194,7 @@ void PrimitiveGUI_SphereDlg::ConstructorsClicked( int constructorId )
resize( minimumSizeHint() );
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
@ -252,7 +252,7 @@ void PrimitiveGUI_SphereDlg::SelectionIntoArgument()
myPoint = aSelectedObject;
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -314,7 +314,7 @@ void PrimitiveGUI_SphereDlg::enterEvent( QEvent* )
//=================================================================================
void PrimitiveGUI_SphereDlg::ValueChangedInSpinBox()
{
displayPreview();
displayPreview(true);
}

View File

@ -200,7 +200,7 @@ void PrimitiveGUI_TorusDlg::ConstructorsClicked (int constructorId)
resize(minimumSizeHint());
SelectionIntoArgument();
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -276,7 +276,7 @@ void PrimitiveGUI_TorusDlg::SelectionIntoArgument()
}
}
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -316,7 +316,7 @@ void PrimitiveGUI_TorusDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
displayPreview(true);
}
//=================================================================================
@ -349,7 +349,7 @@ void PrimitiveGUI_TorusDlg::enterEvent (QEvent*)
//=================================================================================
void PrimitiveGUI_TorusDlg::ValueChangedInSpinBox()
{
displayPreview();
displayPreview(true);
}
//=================================================================================

View File

@ -157,6 +157,8 @@ void RepairGUI_GlueDlg::Init()
//globalSelection( GEOM_COMPOUND );
mainFrame()->GroupBoxPublish->show();
//Hide preview checkbox
mainFrame()->CheckBoxPreview->hide();
/* signals and slots connections */
connect( buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));
@ -237,7 +239,7 @@ void RepairGUI_GlueDlg::ConstructorsClicked( int constructorId )
updateGeometry();
resize( minimumSizeHint() );
displayPreview();
processPreview();
updateButtonState();
activateSelection();
SelectionIntoArgument();

View File

@ -123,6 +123,8 @@ void RepairGUI_LimitToleranceDlg::Init()
//globalSelection(GEOM_COMPOUND);
mainFrame()->GroupBoxPublish->show();
//Hide preview checkbox
mainFrame()->CheckBoxPreview->hide();
/* signals and slots connections */
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));

View File

@ -107,6 +107,8 @@ void RepairGUI_RemoveExtraEdgesDlg::Init()
activateSelection();
mainFrame()->GroupBoxPublish->show();
//Hide preview checkbox
mainFrame()->CheckBoxPreview->hide();
/* signals and slots connections */
connect( buttonOk(), SIGNAL( clicked() ), this, SLOT( ClickOnOk() ) );

View File

@ -112,6 +112,8 @@ void RepairGUI_SuppressFacesDlg::Init()
myFacesInd->length(0);
mainFrame()->GroupBoxPublish->show();
//Hide preview checkbox
mainFrame()->CheckBoxPreview->hide();
// signals and slots connections
connect(buttonOk(), SIGNAL(clicked()), this, SLOT(ClickOnOk()));

View File

@ -171,7 +171,7 @@ void TransformationGUI_MirrorDlg::ConstructorsClicked (int constructorId)
SelectionIntoArgument();
}
else {
displayPreview();
processPreview();
}
}
@ -243,7 +243,7 @@ void TransformationGUI_MirrorDlg::SelectionIntoArgument()
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -292,7 +292,7 @@ void TransformationGUI_MirrorDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -252,7 +252,7 @@ void TransformationGUI_MultiRotationDlg::ConstructorsClicked (int constructorId)
SelectionIntoArgument();
}
else {
displayPreview();
processPreview();
}
}
@ -334,7 +334,7 @@ void TransformationGUI_MultiRotationDlg::SelectionIntoArgument()
myEditCurrentArgument->setText("");
}
displayPreview();
processPreview();
}
//=================================================================================
@ -386,7 +386,7 @@ void TransformationGUI_MultiRotationDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -437,7 +437,7 @@ void TransformationGUI_MultiRotationDlg::ValueChangedInSpinBox (double newValue)
else if (send == GroupDimensions->SpinBox_DX2)
myStep = newValue;
displayPreview();
processPreview();
}
//=================================================================================
@ -453,7 +453,7 @@ void TransformationGUI_MultiRotationDlg::ValueChangedInSpinBox (int newValue)
else if (send == GroupDimensions->SpinBox_DY2)
myNbTimes2 = newValue;
displayPreview();
processPreview();
}
//=================================================================================
@ -469,7 +469,7 @@ void TransformationGUI_MultiRotationDlg::ReverseAngle()
if (aConstructorId == 1)
GroupDimensions->SpinBox_DX1->setValue(myAng);
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -282,7 +282,7 @@ void TransformationGUI_MultiTranslationDlg::ConstructorsClicked (int constructor
SelectionIntoArgument();
}
else {
displayPreview();
processPreview();
}
}
@ -378,7 +378,7 @@ void TransformationGUI_MultiTranslationDlg::SelectionIntoArgument()
myEditCurrentArgument->setText("");
}
displayPreview();
processPreview();
}
//=================================================================================
@ -444,7 +444,7 @@ void TransformationGUI_MultiTranslationDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -524,7 +524,7 @@ void TransformationGUI_MultiTranslationDlg::ValueChangedInSpinBox (double newVal
break;
}
displayPreview();
processPreview();
}
//=================================================================================
@ -547,7 +547,7 @@ void TransformationGUI_MultiTranslationDlg::ValueChangedInSpinBox (int newValue)
break;
}
displayPreview();
processPreview();
}
//=================================================================================
@ -565,7 +565,7 @@ void TransformationGUI_MultiTranslationDlg::ReverseStepU()
else if (aConstructorId == 1)
GroupDimensions->SpinBox_DX1->setValue(myStepU);
displayPreview();
processPreview();
}
//=================================================================================
@ -578,7 +578,7 @@ void TransformationGUI_MultiTranslationDlg::ReverseStepV()
GroupDimensions->SpinBox_DX2->setValue(myStepV);
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -176,7 +176,7 @@ void TransformationGUI_OffsetDlg::SelectionIntoArgument()
myEditCurrentArgument->setText("");
}
displayPreview();
processPreview();
}
@ -229,7 +229,7 @@ void TransformationGUI_OffsetDlg::ActivateThisDialog()
//=================================================================================
void TransformationGUI_OffsetDlg::ValueChangedInSpinBox()
{
displayPreview();
processPreview();
}

View File

@ -248,7 +248,7 @@ void TransformationGUI_PositionDlg::ConstructorsClicked (int constructorId)
SelectionIntoArgument();
}
else {
displayPreview();
processPreview();
}
}
@ -274,7 +274,7 @@ void TransformationGUI_PositionDlg::SelectionTypeButtonClicked()
//=================================================================================
void TransformationGUI_PositionDlg::ValueChangedInSpinBox()
{
displayPreview();
processPreview();
}
//=================================================================================
@ -369,7 +369,7 @@ void TransformationGUI_PositionDlg::SelectionIntoArgument()
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -460,7 +460,7 @@ void TransformationGUI_PositionDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -215,7 +215,7 @@ void TransformationGUI_RotationDlg::ConstructorsClicked (int constructorId)
SelectionIntoArgument();
}
else {
displayPreview();
processPreview();
}
}
@ -328,7 +328,7 @@ void TransformationGUI_RotationDlg::SelectionIntoArgument()
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -401,7 +401,7 @@ void TransformationGUI_RotationDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -443,7 +443,7 @@ void TransformationGUI_RotationDlg::TextValueChangedInSpinBox( const QString& s)
//=================================================================================
void TransformationGUI_RotationDlg::ValueChangedInSpinBox()
{
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -235,7 +235,7 @@ void TransformationGUI_ScaleDlg::ConstructorsClicked (int constructorId)
SelectionIntoArgument();
}
else {
displayPreview();
processPreview();
}
}
@ -304,7 +304,7 @@ void TransformationGUI_ScaleDlg::SelectionIntoArgument()
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -342,7 +342,7 @@ void TransformationGUI_ScaleDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -374,7 +374,7 @@ void TransformationGUI_ScaleDlg::enterEvent (QEvent*)
//=================================================================================
void TransformationGUI_ScaleDlg::ValueChangedInSpinBox()
{
displayPreview();
processPreview();
}
//=================================================================================

View File

@ -261,7 +261,7 @@ void TransformationGUI_TranslationDlg::ConstructorsClicked (int constructorId)
SelectionIntoArgument();
}
else {
displayPreview();
processPreview();
}
}
@ -356,7 +356,7 @@ void TransformationGUI_TranslationDlg::SelectionIntoArgument()
}
}
displayPreview();
processPreview();
}
//=================================================================================
@ -411,7 +411,7 @@ void TransformationGUI_TranslationDlg::SetEditCurrentArgument()
send->setDown(true);
// seems we need it only to avoid preview disappearing, caused by selection mode change
displayPreview();
processPreview();
}
//=================================================================================
@ -443,7 +443,7 @@ void TransformationGUI_TranslationDlg::enterEvent (QEvent*)
//=================================================================================
void TransformationGUI_TranslationDlg::ValueChangedInSpinBox()
{
displayPreview();
processPreview();
}
//=================================================================================
@ -639,7 +639,7 @@ void TransformationGUI_TranslationDlg::CreateCopyModeChanged()
void TransformationGUI_TranslationDlg::ActivateDistanceChanged()
{
GroupPoints->SpinBox3->setEnabled( GroupPoints->CheckBox1->isChecked() );
displayPreview();
processPreview();
}
//=================================================================================