Author: remi
Date: 2008-09-16 21:26:49 +0200 (Tue, 16 Sep 2008)
New Revision: 1857
Modified:
software_suite_v2/tuxware/pytuxisalive/trunk/src/tuxisalive/api/TuxAPITTS.py
Log:
* added a function to set the source encoding
Modified:
software_suite_v2/tuxware/pytuxisalive/trunk/src/tuxisalive/api/TuxAPITTS.py
===================================================================
---
software_suite_v2/tuxware/pytuxisalive/trunk/src/tuxisalive/api/TuxAPITTS.py
2008-09-16 19:26:00 UTC (rev 1856)
+++
software_suite_v2/tuxware/pytuxisalive/trunk/src/tuxisalive/api/TuxAPITTS.py
2008-09-16 19:26:49 UTC (rev 1857)
@@ -71,6 +71,15 @@
import sys
self.__encoding = sys.stdin.encoding
+ def setEncoding(self, encoding = "latin-1"):
+ """Set the source encoding. The speak functions need to encode the
+ text to speak to "utf-8" before to sending it to the HTTP server.
+
+ @param encoding: source encoding
+ example : "latin-1", "utf-8", "cp1252", ...
+ """
+ self.__encoding = encoding
+
def setPitch(self, value):
"""Set the pitch of the locutor.
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
Tux-droid-svn mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/tux-droid-svn