diff --git a/cockatrice/cockatrice.qrc b/cockatrice/cockatrice.qrc index b4d2f05e..34aacb68 100644 --- a/cockatrice/cockatrice.qrc +++ b/cockatrice/cockatrice.qrc @@ -25,6 +25,7 @@ resources/hand.svg resources/pencil.svg resources/icon_search.svg + resources/icon_search_black.svg resources/icon_clearsearch.svg resources/icon_update.png resources/icon_view.svg diff --git a/cockatrice/resources/icon_search_black.svg b/cockatrice/resources/icon_search_black.svg new file mode 100644 index 00000000..05439a12 --- /dev/null +++ b/cockatrice/resources/icon_search_black.svg @@ -0,0 +1,198 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + image/svg+xml + + + + + + + + + + + + \ No newline at end of file diff --git a/cockatrice/src/tab_deck_editor.cpp b/cockatrice/src/tab_deck_editor.cpp index 82a356d1..8c4e9e8e 100644 --- a/cockatrice/src/tab_deck_editor.cpp +++ b/cockatrice/src/tab_deck_editor.cpp @@ -51,9 +51,10 @@ TabDeckEditor::TabDeckEditor(TabSupervisor *_tabSupervisor, QWidget *parent) aClearSearch->setIcon(QIcon(":/resources/icon_clearsearch.svg")); connect(aClearSearch, SIGNAL(triggered()), this, SLOT(actClearSearch())); - searchLabel = new QLabel(); searchEdit = new SearchLineEdit; - searchLabel->setBuddy(searchEdit); + searchEdit->addAction(QIcon(":/resources/icon_search_black.svg"), QLineEdit::LeadingPosition); + searchEdit->setObjectName("searchEdit"); + searchEdit->setStyleSheet("#searchEdit{background:#DFE0E5;border-radius:13px;padding:5px 0px;}#searchEdit:focus{background:#EBEBEB;}"); setFocusProxy(searchEdit); setFocusPolicy(Qt::ClickFocus); @@ -73,7 +74,6 @@ TabDeckEditor::TabDeckEditor(TabSupervisor *_tabSupervisor, QWidget *parent) QHBoxLayout *searchLayout = new QHBoxLayout; searchLayout->addWidget(deckEditToolBar); - searchLayout->addWidget(searchLabel); searchLayout->addWidget(searchEdit); databaseModel = new CardDatabaseModel(db, this); @@ -293,7 +293,6 @@ void TabDeckEditor::retranslateUi() { aCardTextOnly->setText(tr("Show card text only")); aClearSearch->setText(tr("&Clear search")); - searchLabel->setText(tr("&Search for:")); nameLabel->setText(tr("Deck &name:")); commentsLabel->setText(tr("&Comments:")); diff --git a/cockatrice/src/tab_deck_editor.h b/cockatrice/src/tab_deck_editor.h index dd3b56ac..8db00e73 100644 --- a/cockatrice/src/tab_deck_editor.h +++ b/cockatrice/src/tab_deck_editor.h @@ -85,7 +85,6 @@ private: QTreeView *deckView; KeySignals deckViewKeySignals; CardFrame *cardInfo; - QLabel *searchLabel; SearchLineEdit *searchEdit; KeySignals searchKeySignals;