Icon refresh: First step towards the new Qt Creator themes

http://blog.qt.io/blog/author/didesous/ announced new designs/themes
for Qt Creator. This patch replaces many of the existing toolbar icons
with recolorizable masks for better theming support.

Change-Id: I557aa485205fe2624f33724226f698c303342b40
Reviewed-by: Christian Kandeler <christian.kandeler@theqtcompany.com>
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
This commit is contained in:
Alessandro Portale
2015-10-19 12:55:13 +02:00
parent e6d038364f
commit b8bdc6f669
224 changed files with 1371 additions and 878 deletions

View File

@@ -36,6 +36,8 @@
#include "settings.h"
#include "constants.h"
#include <utils/themehelper.h>
namespace Todo {
namespace Internal {
@@ -69,7 +71,8 @@ void OptionsDialog::setSettings(const Settings &settings)
void OptionsDialog::addToKeywordsList(const Keyword &keyword)
{
QListWidgetItem *item = new QListWidgetItem(QIcon(keyword.iconResource), keyword.name);
QListWidgetItem *item = new QListWidgetItem(
Utils::ThemeHelper::themedIcon(keyword.iconResource), keyword.name);
item->setData(Qt::UserRole, keyword.iconResource);
item->setBackgroundColor(keyword.color);
ui->keywordsList->addItem(item);
@@ -120,7 +123,7 @@ void OptionsDialog::editKeyword(QListWidgetItem *item)
KeywordDialog *keywordDialog = new KeywordDialog(keyword, keywordNamesButThis, this);
if (keywordDialog->exec() == QDialog::Accepted) {
keyword = keywordDialog->keyword();
item->setIcon(QIcon(keyword.iconResource));
item->setIcon(Utils::ThemeHelper::themedIcon(keyword.iconResource));
item->setText(keyword.name);
item->setData(Qt::UserRole, keyword.iconResource);
item->setBackgroundColor(keyword.color);