diff --git a/src/cthulhu/scripts/web/speech_generator.py b/src/cthulhu/scripts/web/speech_generator.py index b420214..11b57f2 100644 --- a/src/cthulhu/scripts/web/speech_generator.py +++ b/src/cthulhu/scripts/web/speech_generator.py @@ -560,6 +560,9 @@ class SpeechGenerator(speech_generator.SpeechGenerator): if roledescription: result = [roledescription] result.extend(self.voice(speech_generator.SYSTEM, obj=obj, **args)) + # aria-roledescription replaces the standard role name, so return + # early to avoid announcing both (e.g. "Message" + "article"). + return result role = args.get('role', AXObject.get_role(obj)) roleSoundPresentation = cthulhu.cthulhuApp.settingsManager.getSetting('roleSoundPresentation')