MCPcopy Create free account
hub / github.com/KDE/labplot / initGeneralTab

Method initGeneralTab

src/frontend/dockwidgets/XYEquationCurveDock.cpp:103–121  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

101}
102
103void XYEquationCurveDock::initGeneralTab() {
104 // show the properties of the first curve
105 const auto* equationCurve = static_cast<const XYEquationCurve*>(m_curve);
106 Q_ASSERT(equationCurve);
107 const XYEquationCurve::EquationData& data = equationCurve->equationData();
108 uiGeneralTab.cbType->setCurrentIndex(static_cast<int>(data.type));
109 this->typeChanged(static_cast<int>(data.type));
110 uiGeneralTab.teEquation1->setText(data.expression1);
111 uiGeneralTab.teEquation2->setText(data.expression2);
112 uiGeneralTab.teMin->setText(data.min);
113 uiGeneralTab.teMax->setText(data.max);
114 uiGeneralTab.sbCount->setValue(data.count);
115
116 uiGeneralTab.chkLegendVisible->setChecked(m_curve->legendVisible());
117 uiGeneralTab.chkVisible->setChecked(m_curve->isVisible());
118
119 // Slots
120 connect(m_equationCurve, &XYEquationCurve::equationDataChanged, this, &XYEquationCurveDock::curveEquationDataChanged);
121}
122
123/*!
124 sets the curves. The properties of the curves in the list \c list can be edited in this widget.

Callers

nothing calls this directly

Calls 5

typeChangedMethod · 0.95
setCurrentIndexMethod · 0.45
setTextMethod · 0.45
setValueMethod · 0.45
isVisibleMethod · 0.45

Tested by

no test coverage detected