From a3b3b0850d93bf61ea530574a66c892174f26880 Mon Sep 17 00:00:00 2001 From: Siyuan Yan <44753941+Madoshakalaka@users.noreply.github.com> Date: Wed, 20 Aug 2025 01:31:31 +0900 Subject: [PATCH] Hi res microhpone icon for the recording dialog (#4262) * Replace media-record.png with SVG icon - Added SVG version of the microphone icon (from Font Awesome Free v7.0.0) - Updated sound.py to use QIcon for proper SVG support - Icon now displays at 60x60 pixels * Remove obsolete media-record.png icon The PNG icon has been replaced with an SVG version * Update CONTRIBUTORS * Replace icon with AnkiMobile's record icon CC-BY requires attribution, and we don't currently have a way to describe those attributions in a way the mobile clients can also include automatically. For now, I've switched it to an icon I authored myself to avoid the issue. --------- Co-authored-by: Damien Elmes Co-authored-by: Damien Elmes --- CONTRIBUTORS | 1 + qt/aqt/data/qt/icons/media-record.png | Bin 727 -> 0 bytes qt/aqt/data/qt/icons/media-record.svg | 27 ++++++++++++++++++++++++++ qt/aqt/sound.py | 3 ++- 4 files changed, 30 insertions(+), 1 deletion(-) delete mode 100644 qt/aqt/data/qt/icons/media-record.png create mode 100644 qt/aqt/data/qt/icons/media-record.svg diff --git a/CONTRIBUTORS b/CONTRIBUTORS index 3f6a37ba8..176689c93 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -237,6 +237,7 @@ Kevin Nakamura Bradley Szoke jcznk Thomas Rixen +Siyuan Mattuwu Yan ******************** diff --git a/qt/aqt/data/qt/icons/media-record.png b/qt/aqt/data/qt/icons/media-record.png deleted file mode 100644 index 776e38f6a605b1ab654a3eb07fc508cd134388c4..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 727 zcmV;|0x127P)AaVOc0nLY!EhRjpRtkb%O7(4~O`q`!R{b^PTOxvlon3xYS(g zMrxwkE>cfYf21DSi^vtSk@|Z_TlMT@J9`~8O&MfkZcHnH$H(swYDq#m(*{=3Qf5i=wWQG+WWMVtF-eC0z5QV(NFIpEiVOg@7$r547^i_dR69Gg8RpyW>i3Lt9-QR~CEF-T2rt@wffX@wq2UYTrA^)S54AqoNz~J~y5A%^{QPs`@ z&|ygcTv~n;UFl4ieI=0-yYpB{Y4^w?Q8D`>c}-ZvD}B|zGJut{0IXa3u2*q_xm*D} z$w{g@wi-5?YbTBidac&KU_`a+8sJ9U(Kgj-9+dkm@Ifn+uAz0@52il$8d^qEs6!XzFhd=o1xSEFOeTl@%d#=xit$K!b%3_Wv+|w5Ei)nuOh| zg1N`FV}5hungw{HC-D$VPvUl7s=yzyctf@2xVCtq;9E;;3O1n|c-Xv}Y+sFMOA$B% zN8kt?fdi5i@;#1-Yi)vwH6n8|WnbiF9!eF_r6X_zo{#(qFaV$&bY~{&6?Oms002ov JPDHLkV1l9sLva8A diff --git a/qt/aqt/data/qt/icons/media-record.svg b/qt/aqt/data/qt/icons/media-record.svg new file mode 100644 index 000000000..894787f6c --- /dev/null +++ b/qt/aqt/data/qt/icons/media-record.svg @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/qt/aqt/sound.py b/qt/aqt/sound.py index 25fe07e53..e62786871 100644 --- a/qt/aqt/sound.py +++ b/qt/aqt/sound.py @@ -743,7 +743,8 @@ class RecordDialog(QDialog): def _setup_dialog(self) -> None: self.setWindowTitle("Anki") icon = QLabel() - icon.setPixmap(QPixmap("icons:media-record.png")) + qicon = QIcon("icons:media-record.svg") + icon.setPixmap(qicon.pixmap(60, 60)) self.label = QLabel("...") hbox = QHBoxLayout() hbox.addWidget(icon)