From 5d4b00a11d72da53db24045ee94243d88ce7ff4a Mon Sep 17 00:00:00 2001 From: Luc Mcgrady Date: Mon, 10 Nov 2025 13:03:53 +0000 Subject: [PATCH 1/3] Fix/Per deck retention not used when card is moved to filtered deck (#4413) * Fix/Per deck retention not used for filtered decks * improve error * Perf: prevent double "home_deck" read * Perf: prevent duplicate database read when home deck --- rslib/src/scheduler/answering/mod.rs | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/rslib/src/scheduler/answering/mod.rs b/rslib/src/scheduler/answering/mod.rs index 6ff8c6e2d..a71c6330f 100644 --- a/rslib/src/scheduler/answering/mod.rs +++ b/rslib/src/scheduler/answering/mod.rs @@ -443,9 +443,20 @@ impl Collection { .storage .get_deck(card.deck_id)? .or_not_found(card.deck_id)?; - let config = self.home_deck_config(deck.config_id(), card.original_deck_id)?; + let home_deck = if card.original_deck_id.0 == 0 { + &deck + } else { + &self + .storage + .get_deck(card.original_deck_id)? + .or_not_found(card.original_deck_id)? + }; + let config = self + .storage + .get_deck_config(home_deck.config_id().or_invalid("home deck is filtered")?)? + .unwrap_or_default(); - let desired_retention = deck.effective_desired_retention(&config); + let desired_retention = home_deck.effective_desired_retention(&config); let fsrs_enabled = self.get_config_bool(BoolKey::Fsrs); let fsrs_next_states = if fsrs_enabled { let params = config.fsrs_params(); From c2fddcaf42716682c46880b0d1bf7cb477674e27 Mon Sep 17 00:00:00 2001 From: Nechaiter <164061016+Nechaiter@users.noreply.github.com> Date: Mon, 10 Nov 2025 10:18:57 -0300 Subject: [PATCH 2/3] Fix FindDuplicates dialog size exceeding screen bounds (#4426) --- CONTRIBUTORS | 1 + qt/aqt/forms/finddupes.ui | 3 +++ qt/aqt/utils.py | 2 +- 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CONTRIBUTORS b/CONTRIBUTORS index d90b7dbcc..2ec25da2d 100644 --- a/CONTRIBUTORS +++ b/CONTRIBUTORS @@ -254,6 +254,7 @@ nav1s Ranjit Odedra Eltaurus jariji +Francisco Esteva ******************** diff --git a/qt/aqt/forms/finddupes.ui b/qt/aqt/forms/finddupes.ui index 9a7c44c06..9bc8be87b 100644 --- a/qt/aqt/forms/finddupes.ui +++ b/qt/aqt/forms/finddupes.ui @@ -47,6 +47,9 @@ QComboBox::NoInsert + + QComboBox::SizeAdjustPolicy::AdjustToMinimumContentsLengthWithIcon + diff --git a/qt/aqt/utils.py b/qt/aqt/utils.py index 43efc513f..ae88dadcb 100644 --- a/qt/aqt/utils.py +++ b/qt/aqt/utils.py @@ -809,7 +809,7 @@ def ensureWidgetInScreenBoundaries(widget: QWidget) -> None: wsize = widget.size() cappedWidth = min(geom.width(), wsize.width()) cappedHeight = min(geom.height(), wsize.height()) - if cappedWidth > wsize.width() or cappedHeight > wsize.height(): + if cappedWidth < wsize.width() or cappedHeight < wsize.height(): widget.resize(QSize(cappedWidth, cappedHeight)) # ensure widget is inside top left From 9facea0a6616995458421abace3f54981a53909c Mon Sep 17 00:00:00 2001 From: Lee Doughty <32392044+leedoughty@users.noreply.github.com> Date: Wed, 12 Nov 2025 19:55:47 +0000 Subject: [PATCH 3/3] feat(tts): fallback to Apple Samantha voice for TTS on macOS (#4420) * Fallback to Apple Samantha voice for en_US TTS on macOS * Use prefix match for Apple Samantha voice fallback --- qt/aqt/tts.py | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/qt/aqt/tts.py b/qt/aqt/tts.py index d559fb41f..f77e5c975 100644 --- a/qt/aqt/tts.py +++ b/qt/aqt/tts.py @@ -94,8 +94,15 @@ class TTSPlayer: rank -= 1 - # if no preferred voices match, we fall back on language - # with a rank of -100 + # if no requested voices match, use a preferred fallback voice + # (for example, Apple Samantha) with rank of -50 + for avail in avail_voices: + if avail.lang == tag.lang: + if avail.lang == "en_US" and avail.name.startswith("Apple_Samantha"): + return TTSVoiceMatch(voice=avail, rank=-50) + + # if no requested or preferred voices match, we fall back on + # the first available voice for the language, with a rank of -100 for avail in avail_voices: if avail.lang == tag.lang: return TTSVoiceMatch(voice=avail, rank=-100)