Commit 6dfc02bd authored by Friedrich W. H. Kossebau's avatar Friedrich W. H. Kossebau
Browse files

Set consistently button icons directly in UI files

parent 1bdcb857
......@@ -74,21 +74,15 @@ BranchManager::BranchManager(const QString& repository, KDevelop::DistributedVer
m_ui->branchView->setCurrentIndex(items.first()->index());
}
m_ui->newButton->setIcon(QIcon::fromTheme(QStringLiteral("list-add")));
connect(m_ui->newButton, &QPushButton::clicked, this, &BranchManager::createBranch);
m_ui->deleteButton->setIcon(QIcon::fromTheme(QStringLiteral("list-remove")));
connect(m_ui->deleteButton, &QPushButton::clicked, this, &BranchManager::deleteBranch);
m_ui->renameButton->setIcon(QIcon::fromTheme(QStringLiteral("edit-rename")));
connect(m_ui->renameButton, &QPushButton::clicked, this, &BranchManager::renameBranch);
m_ui->checkoutButton->setIcon(QIcon::fromTheme(QStringLiteral("dialog-ok-apply")));
connect(m_ui->checkoutButton, &QPushButton::clicked, this, &BranchManager::checkoutBranch);
// checkout branch on double-click
connect(m_ui->branchView, &QListView::doubleClicked, this, &BranchManager::checkoutBranch);
m_ui->mergeButton->setIcon(QIcon::fromTheme(QStringLiteral("merge")));
connect(m_ui->mergeButton, &QPushButton::clicked, this, &BranchManager::mergeBranch);
m_ui->diffButton->setIcon(QIcon::fromTheme(QStringLiteral("text-x-patch")));
connect(m_ui->diffButton, &QPushButton::clicked, this, &BranchManager::diffFromBranch);
}
......
......@@ -33,6 +33,9 @@
<property name="text">
<string>New</string>
</property>
<property name="icon">
<iconset theme="list-add"/>
</property>
</widget>
</item>
<item>
......@@ -43,6 +46,9 @@
<property name="text">
<string>Delete</string>
</property>
<property name="icon">
<iconset theme="list-remove"/>
</property>
</widget>
</item>
<item>
......@@ -50,6 +56,9 @@
<property name="text">
<string>Rename</string>
</property>
<property name="icon">
<iconset theme="edit-rename"/>
</property>
</widget>
</item>
<item>
......@@ -76,6 +85,9 @@
<property name="text">
<string>Compare to Branch</string>
</property>
<property name="icon">
<iconset theme="text-x-patch"/>
</property>
</widget>
</item>
<item>
......@@ -102,6 +114,9 @@
<property name="text">
<string>Checkout</string>
</property>
<property name="icon">
<iconset theme="dialog-ok-apply"/>
</property>
</widget>
</item>
<item>
......@@ -109,6 +124,9 @@
<property name="text">
<string>Merge</string>
</property>
<property name="icon">
<iconset theme="merge"/>
</property>
</widget>
</item>
<item>
......
......@@ -45,6 +45,9 @@
<property name="text">
<string>Add</string>
</property>
<property name="icon">
<iconset theme="list-add"/>
</property>
</widget>
</item>
<item>
......@@ -58,6 +61,9 @@
<property name="text">
<string>Remove</string>
</property>
<property name="icon">
<iconset theme="list-remove"/>
</property>
</widget>
</item>
</layout>
......
......@@ -52,9 +52,6 @@ CMakePreferences::CMakePreferences(IPlugin* plugin, const ProjectConfigOptions&
m_prefsUi = new Ui::CMakeBuildSettings;
m_prefsUi->setupUi(this);
m_prefsUi->addBuildDir->setIcon(QIcon::fromTheme( QStringLiteral("list-add") ));
m_prefsUi->removeBuildDir->setIcon(QIcon::fromTheme( QStringLiteral("list-remove") ));
m_prefsUi->addBuildDir->setText(QString());
m_prefsUi->removeBuildDir->setText(QString());
m_prefsUi->cacheList->setItemDelegate(new CMakeCacheDelegate(m_prefsUi->cacheList));
......
......@@ -54,9 +54,6 @@ CustomBuildSystemConfigWidget::CustomBuildSystemConfigWidget( QWidget* parent )
{
ui->setupUi( this );
ui->addConfig->setIcon(QIcon::fromTheme( QStringLiteral("list-add") ));
ui->removeConfig->setIcon(QIcon::fromTheme( QStringLiteral("list-remove") ));
// hack taken from kurlrequester, make the buttons a bit less in height so they better match the url-requester
ui->addConfig->setFixedHeight( ui->currentConfig->sizeHint().height() );
ui->removeConfig->setFixedHeight( ui->currentConfig->sizeHint().height() );
......
......@@ -41,6 +41,9 @@
<property name="text">
<string>Add</string>
</property>
<property name="icon">
<iconset theme="list-add"/>
</property>
</widget>
</item>
<item>
......@@ -48,6 +51,9 @@
<property name="text">
<string>Remove</string>
</property>
<property name="icon">
<iconset theme="list-remove"/>
</property>
</widget>
</item>
</layout>
......
......@@ -51,9 +51,6 @@ CompilersWidget::CompilersWidget(QWidget* parent)
m_ui->compilers->setModel(m_compilersModel);
m_ui->compilers->header()->setSectionResizeMode(QHeaderView::Stretch);
m_ui->addButton->setIcon(QIcon::fromTheme(QStringLiteral("list-add")));
m_ui->removeButton->setIcon(QIcon::fromTheme(QStringLiteral("list-remove")));
m_addMenu = new QMenu(m_ui->addButton);
m_addMenu->clear();
......
......@@ -24,6 +24,9 @@
<property name="text">
<string>&amp;Add</string>
</property>
<property name="icon">
<iconset theme="list-add"/>
</property>
</widget>
</item>
<item>
......@@ -31,6 +34,9 @@
<property name="text">
<string>&amp;Remove</string>
</property>
<property name="icon">
<iconset theme="list-remove"/>
</property>
</widget>
</item>
<item>
......
......@@ -54,10 +54,6 @@ ProjectPathsWidget::ProjectPathsWidget( QWidget* parent )
{
ui->setupUi( this );
ui->addPath->setIcon(QIcon::fromTheme(QStringLiteral("list-add")));
ui->removePath->setIcon(QIcon::fromTheme(QStringLiteral("list-remove")));
ui->batchEdit->setIcon(QIcon::fromTheme(QStringLiteral("format-list-unordered")));
// hack taken from kurlrequester, make the buttons a bit less in height so they better match the url-requester
ui->addPath->setFixedHeight( ui->projectPaths->sizeHint().height() );
ui->removePath->setFixedHeight( ui->projectPaths->sizeHint().height() );
......
......@@ -92,6 +92,9 @@
<property name="text">
<string>&amp;Batch Edit...</string>
</property>
<property name="icon">
<iconset theme="format-list-unordered"/>
</property>
</widget>
</item>
</layout>
......@@ -119,8 +122,7 @@
<string/>
</property>
<property name="icon">
<iconset theme="list-add">
<normaloff>.</normaloff>.</iconset>
<iconset theme="list-add"/>
</property>
</widget>
</item>
......@@ -136,8 +138,7 @@
<string/>
</property>
<property name="icon">
<iconset theme="list-remove">
<normaloff>.</normaloff>.</iconset>
<iconset theme="list-remove"/>
</property>
</widget>
</item>
......
......@@ -51,27 +51,21 @@ ProjectBuildSetWidget::ProjectBuildSetWidget( QWidget* parent )
{
m_ui->setupUi( this );
m_ui->addItemButton->setIcon( QIcon::fromTheme( QStringLiteral("list-add") ) );
connect( m_ui->addItemButton, &QToolButton::clicked,
this, &ProjectBuildSetWidget::addItems );
m_ui->removeItemButton->setIcon( QIcon::fromTheme( QStringLiteral("list-remove") ) );
connect( m_ui->removeItemButton, &QToolButton::clicked,
this, &ProjectBuildSetWidget::removeItems );
m_ui->upButton->setIcon( QIcon::fromTheme( QStringLiteral("go-up") ) );
connect( m_ui->upButton, &QToolButton::clicked,
this, &ProjectBuildSetWidget::moveUp );
m_ui->downButton->setIcon( QIcon::fromTheme( QStringLiteral("go-down") ) );
connect( m_ui->downButton, &QToolButton::clicked,
this, &ProjectBuildSetWidget::moveDown );
m_ui->topButton->setIcon( QIcon::fromTheme( QStringLiteral("go-top") ) );
connect( m_ui->topButton, &QToolButton::clicked,
this, &ProjectBuildSetWidget::moveToTop );
m_ui->bottomButton->setIcon( QIcon::fromTheme( QStringLiteral("go-bottom") ) );
connect( m_ui->bottomButton, &QToolButton::clicked,
this, &ProjectBuildSetWidget::moveToBottom );
......
......@@ -35,7 +35,10 @@
<string>Move the selected items to the top</string>
</property>
<property name="text">
<string>...</string>
<string/>
</property>
<property name="icon">
<iconset theme="go-top"/>
</property>
<property name="autoRaise">
<bool>true</bool>
......@@ -64,7 +67,10 @@
<string>Move the selected items up</string>
</property>
<property name="text">
<string>...</string>
<string/>
</property>
<property name="icon">
<iconset theme="go-up"/>
</property>
<property name="autoRaise">
<bool>true</bool>
......@@ -77,7 +83,10 @@
<string>Move the selected item down</string>
</property>
<property name="text">
<string>...</string>
<string/>
</property>
<property name="icon">
<iconset theme="go-down"/>
</property>
<property name="autoRaise">
<bool>true</bool>
......@@ -106,7 +115,10 @@
<string>Move the selected items to the bottom</string>
</property>
<property name="text">
<string>...</string>
<string/>
</property>
<property name="icon">
<iconset theme="go-bottom"/>
</property>
<property name="autoRaise">
<bool>true</bool>
......@@ -188,7 +200,10 @@
<string>Add currently selected items from project tree view to buildset.</string>
</property>
<property name="text">
<string>...</string>
<string/>
</property>
<property name="icon">
<iconset theme="list-add"/>
</property>
<property name="autoRaise">
<bool>true</bool>
......@@ -201,7 +216,10 @@
<string>Remove currently selected item from buildset.</string>
</property>
<property name="text">
<string>...</string>
<string/>
</property>
<property name="icon">
<iconset theme="list-remove"/>
</property>
<property name="autoRaise">
<bool>true</bool>
......
......@@ -46,9 +46,7 @@ QMakeBuilderPreferences::QMakeBuilderPreferences(KDevelop::IPlugin* plugin,
m_prefsUi->setupUi(this);
// display icons instead of text
m_prefsUi->addButton->setIcon(QIcon::fromTheme(QStringLiteral("list-add")));
m_prefsUi->addButton->setText(QString());
m_prefsUi->removeButton->setIcon(QIcon::fromTheme(QStringLiteral("list-remove")));
m_prefsUi->removeButton->setText(QString());
m_chooserUi = new QMakeBuildDirChooser(m_project);
......
......@@ -30,6 +30,9 @@
<property name="text">
<string>Add</string>
</property>
<property name="icon">
<iconset theme="list-add"/>
</property>
</widget>
</item>
<item>
......@@ -43,6 +46,9 @@
<property name="text">
<string>Remove</string>
</property>
<property name="icon">
<iconset theme="list-remove"/>
</property>
</widget>
</item>
</layout>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment