From f70acfdeff0100524ed90c6d3f23890573174521 Mon Sep 17 00:00:00 2001 From: danielhrisca Date: Thu, 26 Oct 2023 11:18:31 +0300 Subject: [PATCH] change search window button text and icon --- src/asammdf/gui/dialogs/advanced_search.py | 8 ++++++-- src/asammdf/gui/ui/search_dialog.py | 2 +- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/src/asammdf/gui/dialogs/advanced_search.py b/src/asammdf/gui/dialogs/advanced_search.py index f082a57c8..51a56cff0 100644 --- a/src/asammdf/gui/dialogs/advanced_search.py +++ b/src/asammdf/gui/dialogs/advanced_search.py @@ -3,7 +3,7 @@ from traceback import format_exc from natsort import natsorted -from PySide6 import QtCore, QtWidgets +from PySide6 import QtCore, QtWidgets, QtGui from ...blocks.utils import extract_xml_comment from ..ui.search_dialog import Ui_SearchDialog @@ -30,7 +30,7 @@ def __init__( show_apply=False, show_pattern=True, apply_text="Apply", - add_window_text="Add window", + add_window_text="Add channels", show_search=True, window_title="Search & select channels", pattern=None, @@ -40,6 +40,10 @@ def __init__( super().__init__(*args, **kwargs) self.setupUi(self) + icon = QtGui.QIcon() + icon.addFile(":/search.png", QtCore.QSize(), QtGui.QIcon.Normal, QtGui.QIcon.Off) + self.setWindowIcon(icon) + self.selection.can_delete_items = True self.selection.all_texts = True diff --git a/src/asammdf/gui/ui/search_dialog.py b/src/asammdf/gui/ui/search_dialog.py index f847056e1..bfd1c8068 100644 --- a/src/asammdf/gui/ui/search_dialog.py +++ b/src/asammdf/gui/ui/search_dialog.py @@ -381,7 +381,7 @@ def retranslateUi(self, SearchDialog): self.label.setText(QCoreApplication.translate("SearchDialog", "Final selection", None)) self.cancel_btn.setText(QCoreApplication.translate("SearchDialog", "Cancel", None)) self.apply_btn.setText(QCoreApplication.translate("SearchDialog", "Apply", None)) - self.add_window_btn.setText(QCoreApplication.translate("SearchDialog", "Add window", None)) + self.add_window_btn.setText(QCoreApplication.translate("SearchDialog", "Add channels", None)) self.label_7.setText(QCoreApplication.translate("SearchDialog", "Search results", None)) self.search_box.setInputMask("") self.search_box.setText("")