OSDN Git Service

Revert 3873 and 3872 (speech dictionarys affect speak typed characters etc) as there...
authorMichael Curran <mick@kulgan.net>
Mon, 4 Oct 2010 03:52:57 +0000 (14:52 +1100)
committerMichael Curran <mick@kulgan.net>
Mon, 4 Oct 2010 03:52:57 +0000 (14:52 +1100)
source/speech.py
user_docs/en/changes.t2t

index 26e106e..2547f12 100755 (executable)
@@ -81,12 +81,11 @@ def _processSymbol(m):
 RE_CONVERT_WHITESPACE = re.compile("[\0\r\n]")\r
 \r
 def processTextSymbols(text,expandPunctuation=False):\r
-       if text:\r
-               text = speechDictHandler.processText(text)\r
        if (text is None) or (len(text)==0) or (isinstance(text,basestring) and (set(text)<=set(characterSymbols.blankList))):\r
                return _("blank") \r
        #Convert non-breaking spaces to spaces\r
        text=text.replace(u'\xa0',u' ')\r
+       text = speechDictHandler.processText(text)\r
        if expandPunctuation:\r
                text = RE_PROCESS_SYMBOLS.sub(_processSymbol, text)\r
        text = RE_CONVERT_WHITESPACE.sub(u" ", text)\r
@@ -94,7 +93,6 @@ def processTextSymbols(text,expandPunctuation=False):
 \r
 def processSymbol(symbol):\r
        if isinstance(symbol,basestring):\r
-               symbol=speechDictHandler.processText(symbol)\r
                symbol=symbol.replace(u'\xa0',u' ')\r
        newSymbol=characterSymbols.names.get(symbol,symbol)\r
        return newSymbol\r
index d3083f0..841a01a 100644 (file)
@@ -10,7 +10,6 @@
 \r
 \r
 == Changes ==\r
-- Speech dictionary entries now also affect the speaking of typed characters, and speaking of single characters when moving over them.\r
 \r
 \r
 == Bug Fixes ==\r