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,7 @@
#include "androidmanager.h"
#include "ui_androidbuildapkwidget.h"
#include <coreplugin/coreconstants.h>
#include <projectexplorer/buildconfiguration.h>
#include <projectexplorer/project.h>
#include <projectexplorer/target.h>
@@ -43,6 +44,7 @@
#include <utils/fancylineedit.h>
#include <utils/pathchooser.h>
#include <utils/themehelper.h>
#include <QFileDialog>
@@ -89,8 +91,12 @@ AndroidBuildApkWidget::AndroidBuildApkWidget(AndroidBuildApkStep *step)
m_ui->KeystoreLocationPathChooser->setInitialBrowsePathBackup(QDir::homePath());
m_ui->KeystoreLocationPathChooser->setPromptDialogFilter(tr("Keystore files (*.keystore *.jks)"));
m_ui->KeystoreLocationPathChooser->setPromptDialogTitle(tr("Select Keystore File"));
m_ui->signingDebugWarningIcon->setPixmap(
Utils::ThemeHelper::themedIconPixmap(QLatin1String(Core::Constants::ICON_WARNING)));
m_ui->signingDebugWarningIcon->hide();
m_ui->signingDebugWarningLabel->hide();
m_ui->signingDebugDeployErrorIcon->setPixmap(
Utils::ThemeHelper::themedIconPixmap(QLatin1String(Core::Constants::ICON_ERROR)));
signPackageCheckBoxToggled(m_step->signPackage());
m_ui->useGradleCheckBox->setChecked(m_step->useGradle());

View File

@@ -65,12 +65,6 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../coreplugin/core.qrc">:/core/images/warning.png</pixmap>
</property>
</widget>
</item>
<item>
@@ -133,12 +127,6 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../coreplugin/core.qrc">:/core/images/error.png</pixmap>
</property>
<property name="alignment">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
</property>
@@ -265,8 +253,6 @@ The APK will not be usable on any other device.</string>
<container>1</container>
</customwidget>
</customwidgets>
<resources>
<include location="../coreplugin/core.qrc"/>
</resources>
<resources/>
<connections/>
</ui>

View File

@@ -50,6 +50,7 @@
#include <texteditor/texteditoractionhandler.h>
#include <texteditor/texteditor.h>
#include <utils/algorithm.h>
#include <utils/themehelper.h>
#include <QLineEdit>
#include <QFileInfo>
@@ -166,7 +167,8 @@ void AndroidManifestEditorWidget::initializePage()
m_packageNameWarning->setVisible(false);
m_packageNameWarningIcon = new QLabel;
m_packageNameWarningIcon->setPixmap(QPixmap(QLatin1String(Core::Constants::ICON_WARNING)));
m_packageNameWarningIcon->setPixmap(
Utils::ThemeHelper::themedIconPixmap(QLatin1String(Core::Constants::ICON_WARNING)));
m_packageNameWarningIcon->setVisible(false);
m_packageNameWarningIcon->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed);

View File

@@ -33,6 +33,7 @@
#include "androidconfigurations.h"
#include <utils/detailswidget.h>
#include <utils/themehelper.h>
#include <coreplugin/coreconstants.h>
#include <coreplugin/icore.h>
#include <projectexplorer/kitmanager.h>
@@ -92,7 +93,7 @@ AndroidPotentialKitWidget::AndroidPotentialKitWidget(QWidget *parent)
: Utils::DetailsWidget(parent)
{
setSummaryText(QLatin1String("<b>Android has not been configured. Create Android kits.</b>"));
setIcon(QIcon(QLatin1String(Core::Constants::ICON_WARNING)));
setIcon(Utils::ThemeHelper::themedIcon(QLatin1String(Core::Constants::ICON_WARNING)));
//detailsWidget->setState(Utils::DetailsWidget::NoSummary);
QWidget *mainWidget = new QWidget(this);
setWidget(mainWidget);

View File

@@ -36,9 +36,11 @@
#include "androidconstants.h"
#include "androidtoolchain.h"
#include <coreplugin/coreconstants.h>
#include <utils/environment.h>
#include <utils/hostosinfo.h>
#include <utils/pathchooser.h>
#include <utils/themehelper.h>
#include <projectexplorer/toolchainmanager.h>
#include <projectexplorer/kitmanager.h>
#include <projectexplorer/kitinformation.h>
@@ -174,6 +176,17 @@ AndroidSettingsWidget::AndroidSettingsWidget(QWidget *parent)
m_ui->downloadAntToolButton->setVisible(!Utils::HostOsInfo::isLinuxHost());
m_ui->downloadOpenJDKToolButton->setVisible(!Utils::HostOsInfo::isLinuxHost());
const QPixmap warningPixmap = Utils::ThemeHelper::themedIconPixmap(
QLatin1String(Core::Constants::ICON_WARNING));
m_ui->jdkWarningIconLabel->setPixmap(warningPixmap);
m_ui->kitWarningIconLabel->setPixmap(warningPixmap);
const QPixmap errorPixmap = Utils::ThemeHelper::themedIconPixmap(
QLatin1String(Core::Constants::ICON_ERROR));
m_ui->sdkWarningIconLabel->setPixmap(errorPixmap);
m_ui->gdbWarningIconLabel->setPixmap(errorPixmap);
m_ui->ndkWarningIconLabel->setPixmap(errorPixmap);
connect(m_ui->gdbWarningLabel, SIGNAL(linkActivated(QString)),
this, SLOT(showGdbWarningDialog()));

View File

@@ -46,9 +46,6 @@
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../coreplugin/core.qrc">:/core/images/warning.png</pixmap>
</property>
</widget>
</item>
<item>
@@ -123,9 +120,6 @@
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../coreplugin/core.qrc">:/core/images/error.png</pixmap>
</property>
</widget>
</item>
<item>
@@ -192,9 +186,6 @@
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../coreplugin/core.qrc">:/core/images/error.png</pixmap>
</property>
</widget>
</item>
<item>
@@ -228,9 +219,6 @@
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../coreplugin/core.qrc">:/core/images/error.png</pixmap>
</property>
</widget>
</item>
<item>
@@ -280,9 +268,6 @@
<property name="text">
<string/>
</property>
<property name="pixmap">
<pixmap resource="../coreplugin/core.qrc">:/core/images/warning.png</pixmap>
</property>
</widget>
</item>
<item>
@@ -476,7 +461,6 @@
</customwidget>
</customwidgets>
<resources>
<include location="../coreplugin/core.qrc"/>
<include location="android.qrc"/>
</resources>
<connections>

View File

@@ -33,6 +33,7 @@
#include <coreplugin/coreconstants.h>
#include <utils/tooltip/tooltip.h>
#include <utils/themehelper.h>
#include <QKeyEvent>
#include <QMessageBox>
@@ -62,7 +63,8 @@ AvdDialog::AvdDialog(int minApiLevel, const QString &targetArch, const AndroidCo
m_avdDialog.nameLineEdit->setValidator(v);
m_avdDialog.nameLineEdit->installEventFilter(this);
m_avdDialog.warningIcon->setPixmap(QPixmap(QLatin1String(Core::Constants::ICON_WARNING)));
m_avdDialog.warningIcon->setPixmap(Utils::ThemeHelper::themedIconPixmap(
QLatin1String(Core::Constants::ICON_WARNING)));
updateApiLevelComboBox();