File tree Expand file tree Collapse file tree 1 file changed +7
-0
lines changed
addon/globalPlugins/MathCAT Expand file tree Collapse file tree 1 file changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -101,6 +101,12 @@ def ConvertSSMLTextForNVDA(text:str, language:str="") -> list:
101101 synth = getSynth ()
102102 _monkeyPatchESpeak ()
103103 wpm = synth ._percentToParam (synth .rate , 80 , 450 )
104+ try :
105+ if synth .rateBoost :
106+ wpm *= 3 # a guess based on espeak -- not sure what oneCore does
107+ except AttributeError :
108+ pass # SAPI voices don't have 'rateBoost' attr
109+
104110 breakMulti = 180.0 / wpm
105111 supported_commands = synth .supportedCommands
106112 use_break = BreakCommand in supported_commands
@@ -485,6 +491,7 @@ def patched_speak(self, speechSequence: SpeechSequence): # noqa: C901
485491 if prosody :
486492 textList .append ("</prosody>" )
487493 text = u"" .join (textList )
494+ # log.info(f"\ntext={text}")
488495 # Added saving old rate and then resetting to that -- work around for https://github.com/nvaccess/nvda/issues/15221
489496 # I'm not clear why this works since _set_rate() is called before the speech is finished speaking
490497 synth = getSynth ()
You can’t perform that action at this time.
0 commit comments