Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/Speak.activity/voice.py
diff options
context:
space:
mode:
Diffstat (limited to 'Speak.activity/voice.py')
-rw-r--r--Speak.activity/voice.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/Speak.activity/voice.py b/Speak.activity/voice.py
index 6cc6f9c..5fc732e 100644
--- a/Speak.activity/voice.py
+++ b/Speak.activity/voice.py
@@ -94,6 +94,9 @@ def allVoices():
return _allVoices
+def by_name(name):
+ return allVoices().get(name, defaultVoice())
+
def defaultVoice():
"""Try to figure out the default voice, from the current locale ($LANG).
Fall back to espeak's voice called Default."""