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

Method updateTextPosition

src/frontend/TemplateHandler.cpp:244–255  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

242}
243
244void TemplateHandler::updateTextPosition(QAction* action) {
245 auto style = static_cast<Qt::ToolButtonStyle>(action->data().toInt());
246
247 // save the current style
248 KConfig config;
249 KConfigGroup group = config.group(QLatin1String("TemplateHandler"));
250 group.writeEntry(QLatin1String("TextPosition"), static_cast<int>(style));
251
252 // update all available template handlers
253 for (auto* handler : templateHandlers)
254 handler->setToolButtonStyle(style);
255}
256
257void TemplateHandler::setToolButtonStyle(Qt::ToolButtonStyle style) {
258 m_tbLoad->setToolButtonStyle(style);

Callers

nothing calls this directly

Calls 3

setToolButtonStyleMethod · 0.80
dataMethod · 0.45
groupMethod · 0.45

Tested by

no test coverage detected