Fall back to OneCore synth on Windows 10 if a 3rd party synth fails to load #9025
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Link to issue number:
Mentioned in pr #8006
Summary of the issue:
If NVDA is configured to load a 3rd party synth and the loading of that synth fails, NVDA then falls back to eSpeak. However on Windows 10, it really should fallback to OneCore, as OneCore is the default synth for NVDA on Windows 10.
This was specifically noticed with the merging of #8006 where if a synth from an incompatible add-on was in use when updating to a 2019.1 pre build, that synth would fail to load due to the add-on being disabled. On Windows 10 this would fallback to eSpeak, but it really should be oneCore.
Description of how this pull request fixes the issue:
In synthDriverHandler there is now a defaultSynthPriorityList which contains the names of all synths (in priority order) that should be tried by default. E.g. oneCore, espeak, silence.
Now if the loading of a synth fails, NVDA will fallback to the next available synth in that list.
For example, if a 3rd party synth fails to load, then on Windows 10, it will go to OneCore. On lower Operating Systems it will go to espeak.
However, if for instance oneCore fails to load, it will try the next thing in the list, which is espeak.
Testing performed:
Set NVDA to a 3rd party synth (NVSpeechPlayer). Disabled the add-on, restarted NVDA, NVDA switched to oneCore.
Known issues with pull request:
None.
Change log entry:
Bug fixes:
If a 3rd party speech synthesizer fails to load, NVDA will fall back to Windows OneCore speech on Windows 10, rather than espeak.