This commit is contained in:
Kovid Goyal 2022-04-26 20:42:39 +05:30
parent 886ba135b5
commit 877a43d85e
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -18,7 +18,10 @@ class VoicesModel(QAbstractTableModel):
def __init__(self, voice_data, default_output_module, parent=None):
super().__init__(parent)
self.voice_data = voice_data
try:
self.current_voices = voice_data[default_output_module]
except KeyError as e:
raise ValueError(_('Speech dispatcher on this system is not configured with any available voices. Install some voices first.')) from e
self.column_headers = (_('Name'), _('Language'), _('Variant'))
def rowCount(self, parent=None):