void NemoThemeFont::setPointSizeDefault() { if (m_pointSize != 24) { m_pointSize = 24; emit pointSizeChanged(); } }
void NemoThemeFont::setPointSize(int pointSize) { if (m_pointSize != pointSize) { m_pointSize = pointSize; emit pointSizeChanged(); } }
void NemoThemeTextField::setPointSize(int pointSize) { if (m_pointSize != pointSize) { m_pointSize = pointSize; emit pointSizeChanged(); } }
void QvisPointControl::processSizeText() { if(ProcessSizeText(lastGoodPointType)) { if(!signalsBlocked()) { if(lastGoodPointType == POINT_TYPE_POINTS || lastGoodPointType == POINT_TYPE_SPHERE) { emit pointSizePixelsChanged(lastGoodSizePixels); } else emit pointSizeChanged(lastGoodSize); } } }
//! Constructor rtCathDataObject::rtCathDataObject() : m_tension(0.0), m_continuity(0.0), m_tipValue(0.0), m_endValue(0.0), m_splineThickness(1.0) { setObjectType("OT_Cath"); // Allocate new objects m_splineProperty = vtkProperty::New(); m_pointProperty = vtkProperty::New(); m_tipProperty = vtkProperty::New(); m_splinePropertyDlg = new rtPropertyChooserDialog(m_splineProperty); m_pointPropertyDlg = new rtPropertyChooserDialog(m_pointProperty); m_tipPropertyDlg = new rtPropertyChooserDialog(m_tipProperty); // Build the GUI setupGUI(); // More than enough coils m_max_coils = 128; // Set the default point size. m_pointSize = 10; m_cathGuiSetup.pointSizeSlider->setValue(m_pointSize); pointSizeChanged(m_pointSize); m_eType = ET_MEAN; // Start with no coils... m_coilIDList.clear(); m_currProperty = "None"; m_currColor = NULL; connect(this, SIGNAL(updateCoilTableSignal()), this, SLOT(updateCoilTable()),Qt::QueuedConnection); connect(this, SIGNAL(cathPropsChanged()), this, SLOT(updatePropertyBox())); connect(rtApplication::instance().getObjectManager(), SIGNAL(objectCreated(int)),this,SLOT(updateColorBox())); connect(rtApplication::instance().getObjectManager(), SIGNAL(objectRemoved(int)),this,SLOT(updateColorBox())); connect(rtApplication::instance().getObjectManager(), SIGNAL(objectRenamed(int)),this,SLOT(updateColorBox())); }
void tst_QPoint::test() { Point point; { QCOMPARE(point.pointSize(),1.0); QCOMPARE(point.vertices().toList().count(),0); } { QSignalSpy spyPointSize(&point,SIGNAL(pointSizeChanged())); point.setPointSize(5.0); QCOMPARE(spyPointSize.size(), 1); QCOMPARE(point.pointSize(),5.0); point.setPointSize(5.0); QCOMPARE(spyPointSize.size(), 1); } { QSignalSpy spyVertices(&point,SIGNAL(verticesChanged())); QVariantList vertices; vertices.append(QVariant(1.0f)); vertices.append(QVariant(2.0f)); vertices.append(QVariant(3.0f)); point.setVertices(vertices); QCOMPARE(spyVertices.size(), 1); QVariantList readVertices = point.vertices().toList(); QCOMPARE(readVertices.count(),3); QCOMPARE(readVertices.at(0).toReal(),1.0); QCOMPARE(readVertices.at(1).toReal(),2.0); QCOMPARE(readVertices.at(2).toReal(),3.0); point.setVertices(vertices); QCOMPARE(spyVertices.size(), 2); } }
WhiteBoardFontChooser::WhiteBoardFontChooser(QWidget* parent) : QDialog(parent), m_textStyle(0) { setupUi(this); m_font = m_fontComboBox->currentFont(); m_fontPointComboBox->setValidator(new QIntValidator(2,300,m_fontPointComboBox)); pointSizeChanged(m_fontPointComboBox->currentText()); m_boldPushButton->setIcon(QIcon::fromTheme("format-text-bold")); m_italicPushButton->setIcon(QIcon::fromTheme("format-text-italic")); m_strikeoutPushButton->setIcon(QIcon::fromTheme("format-text-strikethrough")); m_underlinePushButton->setIcon(QIcon::fromTheme("format-text-underline")); connect(m_boldPushButton, &QToolButton::toggled, this, &WhiteBoardFontChooser::boldToggled); connect(m_italicPushButton, &QToolButton::toggled, this, &WhiteBoardFontChooser::italicToggled); connect(m_strikeoutPushButton, &QToolButton::toggled, this, &WhiteBoardFontChooser::strikeoutToggled); connect(m_underlinePushButton, &QToolButton::toggled, this, &WhiteBoardFontChooser::underlineToggled); connect(m_fontComboBox, &QFontComboBox::currentFontChanged, this, &WhiteBoardFontChooser::currentFontChanged); connect(m_fontPointComboBox, static_cast<void (KComboBox::*)(const QString &)>(&KComboBox::currentIndexChanged), this, &WhiteBoardFontChooser::pointSizeChanged); }