diff options
author | hjk <hjk@qt.io> | 2020-01-10 09:33:24 +0100 |
---|---|---|
committer | hjk <hjk@qt.io> | 2020-01-16 09:53:45 +0000 |
commit | d43b793dd87d5c71f127341002811c2358cc4c9c (patch) | |
tree | eae00ef99adea577889c7dc249c248be443e9888 | |
parent | 3d7a3b4749abad409663806cadec535fb3a041b6 (diff) | |
download | qt-creator-d43b793dd87d5c71f127341002811c2358cc4c9c.tar.gz |
Core: Introduce a IOptionsPage::setCategoryIconPath
Less noise on the user side.
Change-Id: I34dea09e8a3c8639f5a7db89b22f8b825b946395
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
30 files changed, 37 insertions, 57 deletions
diff --git a/src/plugins/autotest/testsettingspage.cpp b/src/plugins/autotest/testsettingspage.cpp index bcd569c8d2..1f0ddca7c5 100644 --- a/src/plugins/autotest/testsettingspage.cpp +++ b/src/plugins/autotest/testsettingspage.cpp @@ -147,8 +147,7 @@ TestSettingsPage::TestSettingsPage(const QSharedPointer<TestSettings> &settings) setDisplayName(tr("General")); setCategory(Constants::AUTOTEST_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("AutoTest", Constants::AUTOTEST_SETTINGS_TR)); - setCategoryIcon(Utils::Icon({{":/autotest/images/settingscategory_autotest.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/autotest/images/settingscategory_autotest.png"); } QWidget *TestSettingsPage::widget() diff --git a/src/plugins/beautifier/generaloptionspage.cpp b/src/plugins/beautifier/generaloptionspage.cpp index 28c4354d6e..dae4349d18 100644 --- a/src/plugins/beautifier/generaloptionspage.cpp +++ b/src/plugins/beautifier/generaloptionspage.cpp @@ -73,9 +73,8 @@ GeneralOptionsPage::GeneralOptionsPage(const QStringList &toolIds, QObject *pare setDisplayName(tr("General")); setCategory(Constants::OPTION_CATEGORY); setDisplayCategory(QCoreApplication::translate("Beautifier", "Beautifier")); - setCategoryIcon(Utils::Icon({{":/beautifier/images/settingscategory_beautifier.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); setWidgetCreator([toolIds] { return new GeneralOptionsPageWidget(toolIds); }); + setCategoryIconPath(":/beautifier/images/settingscategory_beautifier.png"); } } // namespace Internal diff --git a/src/plugins/clangtools/clangtoolsplugin.cpp b/src/plugins/clangtools/clangtoolsplugin.cpp index ebc85223f4..104f8ff41c 100644 --- a/src/plugins/clangtools/clangtoolsplugin.cpp +++ b/src/plugins/clangtools/clangtoolsplugin.cpp @@ -85,7 +85,7 @@ public: "Clang Tools")); setCategory("T.Analyzer"); setDisplayCategory(QCoreApplication::translate("Analyzer", "Analyzer")); - setCategoryIcon(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); + setCategoryIconPath(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); setWidgetCreator([] { return new SettingsWidget; }); } }; diff --git a/src/plugins/coreplugin/dialogs/ioptionspage.cpp b/src/plugins/coreplugin/dialogs/ioptionspage.cpp index 636ca3ed4e..531466d8ad 100644 --- a/src/plugins/coreplugin/dialogs/ioptionspage.cpp +++ b/src/plugins/coreplugin/dialogs/ioptionspage.cpp @@ -37,6 +37,8 @@ #include <QLabel> #include <QPushButton> +using namespace Utils; + /*! \class Core::IOptionsPage \mainclass @@ -144,6 +146,11 @@ void Core::IOptionsPage::finish() } } +void Core::IOptionsPage::setCategoryIconPath(const QString &categoryIconPath) +{ + m_categoryIcon = Icon({{categoryIconPath, Theme::PanelTextColorDark}}, Icon::Tint); +} + /*! \fn void IOptionsPage::setId(Id id) diff --git a/src/plugins/coreplugin/dialogs/ioptionspage.h b/src/plugins/coreplugin/dialogs/ioptionspage.h index a5b661ae50..e3ceab0fd0 100644 --- a/src/plugins/coreplugin/dialogs/ioptionspage.h +++ b/src/plugins/coreplugin/dialogs/ioptionspage.h @@ -75,6 +75,7 @@ protected: void setCategory(Id category) { m_category = category; } void setDisplayCategory(const QString &displayCategory) { m_displayCategory = displayCategory; } void setCategoryIcon(const Utils::Icon &categoryIcon) { m_categoryIcon = categoryIcon; } + void setCategoryIconPath(const QString &categoryIconPath); Id m_id; Id m_category; diff --git a/src/plugins/coreplugin/generalsettings.cpp b/src/plugins/coreplugin/generalsettings.cpp index 9bc5a8fca1..7bf301b676 100644 --- a/src/plugins/coreplugin/generalsettings.cpp +++ b/src/plugins/coreplugin/generalsettings.cpp @@ -58,8 +58,8 @@ GeneralSettings::GeneralSettings() setDisplayName(tr("Interface")); setCategory(Constants::SETTINGS_CATEGORY_CORE); setDisplayCategory(QCoreApplication::translate("Core", "Environment")); - setCategoryIcon(Utils::Icon({{":/core/images/settingscategory_core.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/core/images/settingscategory_core.png"); + m_defaultShowShortcutsInContextMenu = QGuiApplication::styleHints() ->showShortcutsInContextMenus(); } diff --git a/src/plugins/cpaster/settingspage.cpp b/src/plugins/cpaster/settingspage.cpp index 1054b4500c..497e19019f 100644 --- a/src/plugins/cpaster/settingspage.cpp +++ b/src/plugins/cpaster/settingspage.cpp @@ -69,8 +69,7 @@ SettingsPage::SettingsPage(const QSharedPointer<Settings> &settings, QObject *pa setDisplayName(tr("General")); setCategory(Constants::CPASTER_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("CodePaster", "Code Pasting")); - setCategoryIcon(Utils::Icon({{":/cpaster/images/settingscategory_cpaster.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/cpaster/images/settingscategory_cpaster.png"); } SettingsPage::~SettingsPage() = default; diff --git a/src/plugins/cppcheck/cppcheckoptions.cpp b/src/plugins/cppcheck/cppcheckoptions.cpp index d0392c167b..a3070560bd 100644 --- a/src/plugins/cppcheck/cppcheckoptions.cpp +++ b/src/plugins/cppcheck/cppcheckoptions.cpp @@ -146,7 +146,7 @@ CppcheckOptionsPage::CppcheckOptionsPage(CppcheckTool &tool, CppcheckTrigger &tr setDisplayName(tr("Cppcheck")); setCategory("T.Analyzer"); setDisplayCategory(QCoreApplication::translate("Analyzer", "Analyzer")); - setCategoryIcon(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); + setCategoryIconPath(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); CppcheckOptions options; if (Utils::HostOsInfo::isAnyUnixHost()) { diff --git a/src/plugins/cpptools/cppcodemodelsettingspage.cpp b/src/plugins/cpptools/cppcodemodelsettingspage.cpp index 5aa5c6143c..0ba534e718 100644 --- a/src/plugins/cpptools/cppcodemodelsettingspage.cpp +++ b/src/plugins/cpptools/cppcodemodelsettingspage.cpp @@ -166,9 +166,7 @@ CppCodeModelSettingsPage::CppCodeModelSettingsPage(QSharedPointer<CppCodeModelSe setDisplayName(QCoreApplication::translate("CppTools",Constants::CPP_CODE_MODEL_SETTINGS_NAME)); setCategory(Constants::CPP_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("CppTools", "C++")); - setCategoryIcon(Utils::Icon({{":/projectexplorer/images/settingscategory_cpp.png", - Utils::Theme::PanelTextColorDark}}, - Utils::Icon::Tint)); + setCategoryIconPath(":/projectexplorer/images/settingscategory_cpp.png"); } QWidget *CppCodeModelSettingsPage::widget() diff --git a/src/plugins/debugger/analyzer/analyzericons.h b/src/plugins/debugger/analyzer/analyzericons.h index 0720f44db5..f15c1f34b7 100644 --- a/src/plugins/debugger/analyzer/analyzericons.h +++ b/src/plugins/debugger/analyzer/analyzericons.h @@ -25,13 +25,10 @@ #pragma once -#include <utils/icon.h> - namespace Analyzer { namespace Icons { -const Utils::Icon SETTINGSCATEGORY_ANALYZER({ - {":/images/settingscategory_analyzer.png", Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint); +const char SETTINGSCATEGORY_ANALYZER[] = ":/images/settingscategory_analyzer.png"; } // namespace Icons } // namespace Analyzer diff --git a/src/plugins/debugger/commonoptionspage.cpp b/src/plugins/debugger/commonoptionspage.cpp index 7a5cb42184..2f21805d27 100644 --- a/src/plugins/debugger/commonoptionspage.cpp +++ b/src/plugins/debugger/commonoptionspage.cpp @@ -249,8 +249,7 @@ CommonOptionsPage::CommonOptionsPage() setDisplayName(QCoreApplication::translate("Debugger", "General")); setCategory(DEBUGGER_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("Debugger", "Debugger")); - setCategoryIcon(Icon({{":/debugger/images/settingscategory_debugger.png", - Theme::PanelTextColorDark}}, Icon::Tint)); + setCategoryIconPath(":/debugger/images/settingscategory_debugger.png"); setWidgetCreator([] { return new CommonOptionsPageWidget; }); } diff --git a/src/plugins/fakevim/fakevimplugin.cpp b/src/plugins/fakevim/fakevimplugin.cpp index 393e5380ae..5dd35f75c7 100644 --- a/src/plugins/fakevim/fakevimplugin.cpp +++ b/src/plugins/fakevim/fakevimplugin.cpp @@ -366,8 +366,7 @@ public: setDisplayName(Tr::tr("General")); setCategory(SETTINGS_CATEGORY); setDisplayCategory(Tr::tr("FakeVim")); - setCategoryIcon(Utils::Icon({{":/fakevim/images/settingscategory_fakevim.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/fakevim/images/settingscategory_fakevim.png"); } QWidget *widget() override; diff --git a/src/plugins/help/generalsettingspage.cpp b/src/plugins/help/generalsettingspage.cpp index 3b22a266e0..9d17efcee6 100644 --- a/src/plugins/help/generalsettingspage.cpp +++ b/src/plugins/help/generalsettingspage.cpp @@ -57,8 +57,7 @@ GeneralSettingsPage::GeneralSettingsPage() setDisplayName(tr("General")); setCategory(Help::Constants::HELP_CATEGORY); setDisplayCategory(QCoreApplication::translate("Help", "Help")); - setCategoryIcon(Utils::Icon({{":/help/images/settingscategory_help.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/help/images/settingscategory_help.png"); } QWidget *GeneralSettingsPage::widget() diff --git a/src/plugins/languageclient/languageclientsettings.cpp b/src/plugins/languageclient/languageclientsettings.cpp index fcd3a07b4a..cfafd86cbb 100644 --- a/src/plugins/languageclient/languageclientsettings.cpp +++ b/src/plugins/languageclient/languageclientsettings.cpp @@ -254,8 +254,7 @@ LanguageClientSettingsPage::LanguageClientSettingsPage() setCategory(Constants::LANGUAGECLIENT_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("LanguageClient", Constants::LANGUAGECLIENT_SETTINGS_TR)); - setCategoryIcon(Utils::Icon({{":/languageclient/images/settingscategory_languageclient.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/languageclient/images/settingscategory_languageclient.png"); } LanguageClientSettingsPage::~LanguageClientSettingsPage() diff --git a/src/plugins/nim/settings/nimcodestylesettingspage.cpp b/src/plugins/nim/settings/nimcodestylesettingspage.cpp index d93f4d3ed0..93c67050a7 100644 --- a/src/plugins/nim/settings/nimcodestylesettingspage.cpp +++ b/src/plugins/nim/settings/nimcodestylesettingspage.cpp @@ -50,8 +50,7 @@ NimCodeStyleSettingsPage::NimCodeStyleSettingsPage() setDisplayName(tr(Nim::Constants::C_NIMCODESTYLESETTINGSPAGE_DISPLAY)); setCategory(Nim::Constants::C_NIMCODESTYLESETTINGSPAGE_CATEGORY); setDisplayCategory(tr("Nim")); - setCategoryIcon(Utils::Icon({{":/nim/images/settingscategory_nim.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/nim/images/settingscategory_nim.png"); } NimCodeStyleSettingsPage::~NimCodeStyleSettingsPage() diff --git a/src/plugins/nim/settings/nimtoolssettingspage.cpp b/src/plugins/nim/settings/nimtoolssettingspage.cpp index 05187f869b..99be94460a 100644 --- a/src/plugins/nim/settings/nimtoolssettingspage.cpp +++ b/src/plugins/nim/settings/nimtoolssettingspage.cpp @@ -62,9 +62,7 @@ NimToolsSettingsPage::NimToolsSettingsPage(NimSettings *settings) setDisplayName(tr(Nim::Constants::C_NIMTOOLSSETTINGSPAGE_DISPLAY)); setCategory(Nim::Constants::C_NIMTOOLSSETTINGSPAGE_CATEGORY); setDisplayCategory(tr("Nim")); - setCategoryIcon(Utils::Icon({{":/nim/images/settingscategory_nim.png", - Utils::Theme::PanelTextColorDark - }}, Utils::Icon::Tint)); + setCategoryIconPath(":/nim/images/settingscategory_nim.png"); } NimToolsSettingsPage::~NimToolsSettingsPage() = default; diff --git a/src/plugins/perfprofiler/perfoptionspage.cpp b/src/plugins/perfprofiler/perfoptionspage.cpp index 356b073dd6..d445ecc560 100644 --- a/src/plugins/perfprofiler/perfoptionspage.cpp +++ b/src/plugins/perfprofiler/perfoptionspage.cpp @@ -39,7 +39,7 @@ PerfOptionsPage::PerfOptionsPage() setDisplayName(QCoreApplication::translate("PerfProfiler::PerfOptionsPage", "CPU Usage")); setCategory("T.Analyzer"); setDisplayCategory(QCoreApplication::translate("Analyzer", "Analyzer")); - setCategoryIcon(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); + setCategoryIconPath(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); } QWidget *PerfOptionsPage::widget() diff --git a/src/plugins/projectexplorer/devicesupport/devicesettingspage.cpp b/src/plugins/projectexplorer/devicesupport/devicesettingspage.cpp index e5f27e82d4..bc0285940e 100644 --- a/src/plugins/projectexplorer/devicesupport/devicesettingspage.cpp +++ b/src/plugins/projectexplorer/devicesupport/devicesettingspage.cpp @@ -40,8 +40,7 @@ DeviceSettingsPage::DeviceSettingsPage() setDisplayName(tr("Devices")); setCategory(Constants::DEVICE_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("ProjectExplorer", "Devices")); - setCategoryIcon(Utils::Icon({{":/projectexplorer/images/settingscategory_devices.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/projectexplorer/images/settingscategory_devices.png"); setWidgetCreator([] { return new DeviceSettingsWidget; }); } diff --git a/src/plugins/projectexplorer/devicesupport/sshsettingspage.cpp b/src/plugins/projectexplorer/devicesupport/sshsettingspage.cpp index e11dd23905..71b64b7458 100644 --- a/src/plugins/projectexplorer/devicesupport/sshsettingspage.cpp +++ b/src/plugins/projectexplorer/devicesupport/sshsettingspage.cpp @@ -81,8 +81,7 @@ SshSettingsPage::SshSettingsPage() setDisplayName(SshSettingsWidget::tr("SSH")); setCategory(Constants::DEVICE_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("ProjectExplorer", "SSH")); - setCategoryIcon(Utils::Icon({{":/projectexplorer/images/settingscategory_devices.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/projectexplorer/images/settingscategory_devices.png"); setWidgetCreator([] { return new SshSettingsWidget; }); } diff --git a/src/plugins/projectexplorer/kitoptionspage.cpp b/src/plugins/projectexplorer/kitoptionspage.cpp index d9ebe3f0e0..fc34abf450 100644 --- a/src/plugins/projectexplorer/kitoptionspage.cpp +++ b/src/plugins/projectexplorer/kitoptionspage.cpp @@ -272,8 +272,7 @@ KitOptionsPage::KitOptionsPage() setDisplayName(tr("Kits")); setCategory(Constants::KITS_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("ProjectExplorer", "Kits")); - setCategoryIcon(Utils::Icon({{":/projectexplorer/images/settingscategory_kits.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/projectexplorer/images/settingscategory_kits.png"); } QWidget *KitOptionsPage::widget() diff --git a/src/plugins/projectexplorer/projectexplorersettingspage.cpp b/src/plugins/projectexplorer/projectexplorersettingspage.cpp index ce737773a1..205aa0d9ed 100644 --- a/src/plugins/projectexplorer/projectexplorersettingspage.cpp +++ b/src/plugins/projectexplorer/projectexplorersettingspage.cpp @@ -206,8 +206,7 @@ ProjectExplorerSettingsPage::ProjectExplorerSettingsPage() setDisplayName(tr("General")); setCategory(Constants::BUILD_AND_RUN_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("ProjectExplorer", "Build & Run")); - setCategoryIcon(Utils::Icon({{":/projectexplorer/images/settingscategory_buildrun.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/projectexplorer/images/settingscategory_buildrun.png"); } QWidget *ProjectExplorerSettingsPage::widget() diff --git a/src/plugins/python/pythonsettings.cpp b/src/plugins/python/pythonsettings.cpp index 567d773511..d2d1d74f87 100644 --- a/src/plugins/python/pythonsettings.cpp +++ b/src/plugins/python/pythonsettings.cpp @@ -233,8 +233,7 @@ InterpreterOptionsPage::InterpreterOptionsPage() setDisplayName(PythonSettings::tr("Interpreters")); setCategory(Constants::C_PYTHON_SETTINGS_CATEGORY); setDisplayCategory(PythonSettings::tr("Python")); - setCategoryIcon(Utils::Icon({{":/python/images/settingscategory_python.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/python/images/settingscategory_python.png"); } Interpreter InterpreterOptionsPage::defaultInterpreter() const diff --git a/src/plugins/qbsprojectmanager/qbssettings.cpp b/src/plugins/qbsprojectmanager/qbssettings.cpp index 5fbd19a1bb..22d5059f4b 100644 --- a/src/plugins/qbsprojectmanager/qbssettings.cpp +++ b/src/plugins/qbsprojectmanager/qbssettings.cpp @@ -184,9 +184,7 @@ QbsSettingsPage::QbsSettingsPage() setCategory(Constants::QBS_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("QbsProjectManager", Constants::QBS_SETTINGS_TR_CATEGORY)); - setCategoryIcon( - Utils::Icon({{":/qbsprojectmanager/images/settingscategory_qbsprojectmanager.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/qbsprojectmanager/images/settingscategory_qbsprojectmanager.png"); } QWidget *QbsSettingsPage::widget() diff --git a/src/plugins/qmljstools/qmljscodestylesettingspage.cpp b/src/plugins/qmljstools/qmljscodestylesettingspage.cpp index 6379ffafc4..560fce6f70 100644 --- a/src/plugins/qmljstools/qmljscodestylesettingspage.cpp +++ b/src/plugins/qmljstools/qmljscodestylesettingspage.cpp @@ -127,8 +127,7 @@ QmlJSCodeStyleSettingsPage::QmlJSCodeStyleSettingsPage() setDisplayName(QCoreApplication::translate("QmlJSTools", Constants::QML_JS_CODE_STYLE_SETTINGS_NAME)); setCategory(QmlJSEditor::Constants::SETTINGS_CATEGORY_QML); setDisplayCategory(QCoreApplication::translate("QmlJSEditor", "Qt Quick")); - setCategoryIcon(Utils::Icon({{":/qmljstools/images/settingscategory_qml.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/qmljstools/images/settingscategory_qml.png"); } QWidget *QmlJSCodeStyleSettingsPage::widget() diff --git a/src/plugins/qmlprofiler/qmlprofileroptionspage.cpp b/src/plugins/qmlprofiler/qmlprofileroptionspage.cpp index 9bc52867c0..c67d74fe58 100644 --- a/src/plugins/qmlprofiler/qmlprofileroptionspage.cpp +++ b/src/plugins/qmlprofiler/qmlprofileroptionspage.cpp @@ -39,7 +39,7 @@ QmlProfilerOptionsPage::QmlProfilerOptionsPage() setDisplayName(tr("QML Profiler")); setCategory("T.Analyzer"); setDisplayCategory(tr("Analyzer")); - setCategoryIcon(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); + setCategoryIconPath(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); } QWidget *QmlProfilerOptionsPage::widget() diff --git a/src/plugins/qtsupport/codegensettingspage.cpp b/src/plugins/qtsupport/codegensettingspage.cpp index 2efb90b98c..aaf9bc077b 100644 --- a/src/plugins/qtsupport/codegensettingspage.cpp +++ b/src/plugins/qtsupport/codegensettingspage.cpp @@ -96,9 +96,7 @@ CodeGenSettingsPage::CodeGenSettingsPage() setCategory(CppTools::Constants::CPP_SETTINGS_CATEGORY); setDisplayCategory( QCoreApplication::translate("CppTools", CppTools::Constants::CPP_SETTINGS_NAME)); - setCategoryIcon(Utils::Icon({{":/projectexplorer/images/settingscategory_cpp.png", - Utils::Theme::PanelTextColorDark}}, - Utils::Icon::Tint)); + setCategoryIconPath(":/projectexplorer/images/settingscategory_cpp.png"); setWidgetCreator([] { return new CodeGenSettingsPageWidget; }); } diff --git a/src/plugins/texteditor/texteditoroptionspage.cpp b/src/plugins/texteditor/texteditoroptionspage.cpp index 05a10ec8a1..c95d65daee 100644 --- a/src/plugins/texteditor/texteditoroptionspage.cpp +++ b/src/plugins/texteditor/texteditoroptionspage.cpp @@ -36,6 +36,5 @@ TextEditorOptionsPage::TextEditorOptionsPage(QObject *parent) : { setCategory(Constants::TEXT_EDITOR_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("TextEditor", "Text Editor")); - setCategoryIcon(Utils::Icon({{":/texteditor/images/settingscategory_texteditor.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/texteditor/images/settingscategory_texteditor.png"); } diff --git a/src/plugins/todo/optionspage.cpp b/src/plugins/todo/optionspage.cpp index a39d621892..3a6e13de51 100644 --- a/src/plugins/todo/optionspage.cpp +++ b/src/plugins/todo/optionspage.cpp @@ -48,8 +48,7 @@ OptionsPage::OptionsPage(const Settings &settings, QObject *parent) : setDisplayName(tr("To-Do")); setCategory("To-Do"); setDisplayCategory(tr("To-Do")); - setCategoryIcon(Utils::Icon({{":/todoplugin/images/settingscategory_todo.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/todoplugin/images/settingscategory_todo.png"); } void OptionsPage::setSettings(const Settings &settings) diff --git a/src/plugins/valgrind/valgrindplugin.cpp b/src/plugins/valgrind/valgrindplugin.cpp index 81ed429d3d..79a02e3118 100644 --- a/src/plugins/valgrind/valgrindplugin.cpp +++ b/src/plugins/valgrind/valgrindplugin.cpp @@ -63,7 +63,7 @@ public: setDisplayName(QCoreApplication::translate("Valgrind::Internal::ValgrindOptionsPage", "Valgrind")); setCategory("T.Analyzer"); setDisplayCategory(QCoreApplication::translate("Analyzer", "Analyzer")); - setCategoryIcon(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); + setCategoryIconPath(Analyzer::Icons::SETTINGSCATEGORY_ANALYZER); } QWidget *widget() override diff --git a/src/plugins/vcsbase/vcsbaseoptionspage.cpp b/src/plugins/vcsbase/vcsbaseoptionspage.cpp index ef5a1ea4e1..a1c825e5d7 100644 --- a/src/plugins/vcsbase/vcsbaseoptionspage.cpp +++ b/src/plugins/vcsbase/vcsbaseoptionspage.cpp @@ -48,8 +48,7 @@ VcsBaseOptionsPage::VcsBaseOptionsPage(QObject *parent) : Core::IOptionsPage(par { setCategory(Constants::VCS_SETTINGS_CATEGORY); setDisplayCategory(QCoreApplication::translate("VcsBase", "Version Control")); - setCategoryIcon(Utils::Icon({{":/vcsbase/images/settingscategory_vcs.png", - Utils::Theme::PanelTextColorDark}}, Utils::Icon::Tint)); + setCategoryIconPath(":/vcsbase/images/settingscategory_vcs.png"); } VcsBaseOptionsPage::~VcsBaseOptionsPage() = default; |