// This provides update information when a new object is set void imodvObjedForm::updateObject(int ob, int numObj, int drawType, int drawStyle, QColor color, char *name) { updateColorBox(color); diaSetSpinMMVal(objectSpinBox, 1, numObj, ob); objectSpinBox->setEnabled(numObj > 1); objectSlider->setMaximum(numObj); diaSetSlider(objectSlider, ob); objectSlider->setEnabled(numObj > 1); dataTypeComboBox->setCurrentIndex(drawType); drawStyleComboBox->setCurrentIndex(drawStyle); QString str = name; diaSetEditText(nameLineEdit, str); }
//! Set the GUI widgets. void rtCathDataObject::setupGUI() { QWidget* wid = getBaseWidget(); m_cathGuiSetup.setupUi(wid); // Setup the points table. m_cathGuiSetup.pointsTable->setColumnWidth(0, 60); m_cathGuiSetup.pointsTable->setColumnWidth(1, 50); m_cathGuiSetup.pointsTable->setColumnWidth(2, 60); m_cathGuiSetup.pointsTable->setColumnWidth(3, 50); m_cathGuiSetup.pointsTable->setColumnWidth(4, 50); m_cathGuiSetup.pointsTable->setColumnWidth(5, 50); m_cathGuiSetup.pointsTable->setColumnWidth(6, 50); connect(m_cathGuiSetup.pointsTable, SIGNAL(cellChanged(int,int)), this, SLOT(tableCellChanged(int,int))); connect(m_cathGuiSetup.splinePropButton, SIGNAL(pressed()), this, SLOT(splinePropertyDialog())); connect(m_cathGuiSetup.pointPropButton, SIGNAL(pressed()), this, SLOT(pointPropertyDialog())); connect(m_cathGuiSetup.tipPropButton, SIGNAL(pressed()), this, SLOT(tipPropertyDialog())); connect(m_cathGuiSetup.pointSizeSlider, SIGNAL(valueChanged(int)), this, SLOT(pointSizeChanged(int))); connect(m_splinePropertyDlg, SIGNAL(propertyChanged()), this, SLOT(Modified())); connect(m_pointPropertyDlg, SIGNAL(propertyChanged()), this, SLOT(Modified())); connect(m_tipPropertyDlg, SIGNAL(propertyChanged()), this, SLOT(Modified())); updatePropertyBox(); updateColorBox(); connect(m_cathGuiSetup.propertyBox, SIGNAL(currentIndexChanged(int)), this, SLOT(propertyChanged())); connect(m_cathGuiSetup.colorBox, SIGNAL(currentIndexChanged(int)), this, SLOT(colorChanged(int))); connect( m_cathGuiSetup.thicknessSpinBox, SIGNAL(valueChanged(double)), this, SLOT(splineThicknessChanged(double)) ); connect( m_cathGuiSetup.tensionSpinBox, SIGNAL(valueChanged(double)), this, SLOT(tensionChanged(double)) ); connect( m_cathGuiSetup.continuitySpinBox, SIGNAL(valueChanged(double)), this, SLOT(continuityChanged(double)) ); connect( m_cathGuiSetup.tipSpinBox, SIGNAL(valueChanged(double)), this, SLOT(tipValueChanged(double)) ); connect( m_cathGuiSetup.endSpinBox, SIGNAL(valueChanged(double)), this, SLOT(endValueChanged(double)) ); //gating connect(m_cathGuiSetup.minBox, SIGNAL(valueChanged(int)),this,SLOT(gateBoundsChanged())); }