From 76e01c6f3af7c096e8500cf9cb3d42ec1d5b5434 Mon Sep 17 00:00:00 2001 From: bitcoinafterlife Date: Thu, 17 Jul 2025 22:36:55 -0400 Subject: [PATCH] icons --- __init__.py | 20 ++++++++++++++++++++ qt.py | 15 +++++++-------- 2 files changed, 27 insertions(+), 8 deletions(-) diff --git a/__init__.py b/__init__.py index e69de29..5356ea0 100644 --- a/__init__.py +++ b/__init__.py @@ -0,0 +1,20 @@ +from electrum.i18n import _ +import subprocess +from . import bal_resources +BUILD_NUMBER = 3 +REVISION_NUMBER = 2 +VERSION_NUMBER = 0 +def _version(): + return f'{VERSION_NUMBER}.{REVISION_NUMBER}-{BUILD_NUMBER}' + +version = _version() +author = "Bal Enterprise inc." +fullname = _('B.A.L.') +description = ''.join([ + "", _("Bitcoin After Life"), '
', + _("For more information, visit"), + " https://bitcoin-after.life/
", + "

Version: ", _version(),"

" +]) +#available_for = ['qt', 'cmdline', 'qml'] +available_for = ['qt'] diff --git a/qt.py b/qt.py index de2ab36..389acf8 100644 --- a/qt.py +++ b/qt.py @@ -250,7 +250,6 @@ from electrum.gui.qt.util import ( export_meta_gui, MessageBoxMixin, Buttons, - read_QIcon, export_meta_gui, MessageBoxMixin, char_width_in_lineedit, @@ -380,7 +379,7 @@ class Plugin(BalPlugin,Logger): def create_status_bar(self, sb): self.logger.info("HOOK create status bar") return - b = StatusBarButton(read_QIcon('bal32x32.png'), "Bal "+_("Bitcoin After Life"), + b = StatusBarButton(read_bal_QIcon('bal32x32.png'), "Bal "+_("Bitcoin After Life"), partial(self.setup_dialog, sb), sb.height()) sb.addPermanentWidget(b) @@ -531,8 +530,8 @@ class BalWindow(Logger): - add_optional_tab(self.window.tabs, self.heirs_tab, read_QIcon("heir.png"), _("&Heirs")) - add_optional_tab(self.window.tabs, self.will_tab, read_QIcon("will.png"), _("&Will")) + add_optional_tab(self.window.tabs, self.heirs_tab, read_bal_QIcon("heir.png"), _("&Heirs")) + add_optional_tab(self.window.tabs, self.will_tab, read_bal_QIcon("will.png"), _("&Will")) tools_menu.addSeparator() self.tools_menu.willexecutors_action = tools_menu.addAction(_("&Will-Executors"), self.show_willexecutor_dialog) self.window.view_menu.addSeparator() @@ -847,7 +846,7 @@ class BalWindow(Logger): external_keypairs=external_keypairs, #payment_identifier=payment_identifier, ) - d.setWindowIcon(read_QIcon("bal32x32.png")) + d.setWindowIcon(read_bal_QIcon("bal32x32.png")) except SerializationError as e: self.logger.error('unable to deserialize the transaction') parent.show_critical(_("Electrum was unable to deserialize the transaction:") + "\n" + str(e)) @@ -1439,7 +1438,7 @@ class BalDialog(WindowModalDialog): def __init__(self,parent,title=None, icon = 'bal32x32.png'): self.parent=parent WindowModalDialog.__init__(self,self.parent,title) - self.setWindowIcon(read_QIcon(icon)) + self.setWindowIcon(read_bal_QIcon(icon)) class BalWaitingDialog(BalDialog): updatemessage=pyqtSignal([str], arguments=['message']) @@ -2353,9 +2352,9 @@ class PreviewDialog(BalDialog,MessageBoxMixin): def closeEvent(self, event): event.accept() -def read_QIcon(icon_basename: str=DEFAULT_ICON) -> QIcon: +def read_bal_QIcon(icon_basename: str=DEFAULT_ICON) -> QIcon: return QIcon(icon_path(icon_basename)) -def read_QPixmap(icon_basename: str=DEFAULT_ICON) -> QPixmap: +def read_bal_QPixmap(icon_basename: str=DEFAULT_ICON) -> QPixmap: return QPixmap(icon_path(icon_basename))