imporove emacspakDriver still WiP

This commit is contained in:
chrys 2017-10-21 01:06:35 +02:00
parent a0778748fc
commit d8ec50f769

View File

@ -34,8 +34,7 @@ class driver():
return return
if not queueable: if not queueable:
self.cancel() self.cancel()
self.server.sendline('tts_say ' + '\"' + text +'\"') self.server.sendline('tts_say ' + '\"' + text.replace('"', '\\\"') +'\"')
self.server.sendline('d')
def cancel(self): def cancel(self):
if not self._isInitialized: if not self._isInitialized:
@ -48,7 +47,6 @@ class driver():
def clear_buffer(self): def clear_buffer(self):
if not self._isInitialized: if not self._isInitialized:
return return
print('SpeechDummyDriver: clear_buffer')
def setVoice(self, voice): def setVoice(self, voice):
if not self._isInitialized: if not self._isInitialized:
@ -56,24 +54,18 @@ class driver():
#self.server.sendline('s') #self.server.sendline('s')
def setPitch(self, pitch): def setPitch(self, pitch):
if not self._isInitialized: pass
return
#self.server.sendline('tts_set_speech_rate')
def setRate(self, rate): def setRate(self, rate):
if not self._isInitialized: if not self._isInitialized:
return return
self.server.sendline('tts_set_speech_rate' + str(rate)) self.server.sendline('tts_set_speech_rate' + str(rate))
def setModule(self, module): def setModule(self, module):
if not self._isInitialized: pass
return
def setLanguage(self, language): def setLanguage(self, language):
if not self._isInitialized: if not self._isInitialized:
return return
#self.server.sendline('s')
def setVolume(self, volume): def setVolume(self, volume):
if not self._isInitialized: pass
return
#self.server.sendline('s')