From 9d8782c31ca87b1de1a3d7e60d5bc4c2590479a1 Mon Sep 17 00:00:00 2001 From: David Culley <6276049+davidculley@users.noreply.github.com> Date: Wed, 10 Jul 2024 16:14:51 +0200 Subject: [PATCH] Simplify the format string (#3293) * refactor: simplify format string * chore: add myself to CONTRIBUTORS file --- CONTRIBUTORS | 1 + qt/aqt/editor.py | 16 ++++------------ 2 files changed, 5 insertions(+), 12 deletions(-) diff --git a/CONTRIBUTORS b/CONTRIBUTORS index bff13c38e2f..d91ccc3d2ed 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -177,6 +177,7 @@ RRomeroJr <117.rromero@gmail.com> Xidorn Quan Alexander Bocken James Elmore +David Culley <6276049+davidculley@users.noreply.github.com> Rastislav Kish ******************** diff --git a/qt/aqt/editor.py b/qt/aqt/editor.py index b6c28c30841..0f447bb0291 100644 --- a/qt/aqt/editor.py +++ b/qt/aqt/editor.py @@ -323,25 +323,17 @@ def _addButton( class_ = "rounded" if not disables: class_ += " perm" - return """""".format( - imgelm=imgelm, - cmd=cmd, - tip=tip, - labelelm=labelelm, - id=idstr, - togglesc=toggleScript, - class_=class_, - ) + """ def setupShortcuts(self) -> None: # if a third element is provided, enable shortcut even when no field selected