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

Method loadConfig

src/frontend/dockwidgets/KDEPlotDock.cpp:351–367  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

349}
350
351void KDEPlotDock::loadConfig(KConfig& config) {
352 KConfigGroup group = config.group(QStringLiteral("KDEPlot"));
353
354 // general
355 auto kernelType = group.readEntry(QStringLiteral("kernelType"), static_cast<int>(m_plot->kernelType()));
356 int index = ui.cbKernelType->findData(kernelType);
357 ui.cbKernelType->setCurrentIndex(index);
358
359 auto bandwidthType = group.readEntry(QStringLiteral("bandwidthType"), static_cast<int>(m_plot->bandwidthType()));
360 index = ui.cbBandwidthType->findData(bandwidthType);
361 ui.cbBandwidthType->setCurrentIndex(index);
362
363 ui.sbBandwidth->setValue(group.readEntry(QStringLiteral("bandwidth"), m_plot->bandwidth()));
364
365 // properties of the estimation and margin curves
366 // lineWidget->loadConfig(group);
367}
368
369void KDEPlotDock::loadConfigFromTemplate(KConfig& config) {
370 auto name = TemplateHandler::templateName(config);

Callers 1

Calls 3

groupMethod · 0.45
setCurrentIndexMethod · 0.45
setValueMethod · 0.45

Tested by

no test coverage detected