OSDN Git Service

Microsoft Word support: table navigation commands: Don't speak "edge of table" after...
authorJames Teh <jamie@jantrid.net>
Wed, 22 Sep 2010 02:24:08 +0000 (12:24 +1000)
committerJames Teh <jamie@jantrid.net>
Wed, 22 Sep 2010 02:24:08 +0000 (12:24 +1000)
Fixes #921.

source/NVDAObjects/window/winword.py
user_docs/en/changes.t2t

index 9c507c6..206ee28 100755 (executable)
@@ -353,45 +353,49 @@ class WordDocument(EditableTextWithoutAutoSelectDetection, Window):
                info=self.makeTextInfo("caret")\r
                if not info._rangeObj.Information(wdWithInTable):\r
                        speech.speakMessage(_("not in table"))\r
+                       return\r
                if info._moveInTable(0,1):\r
                        info.updateCaret()\r
                        info.expand(textInfos.UNIT_CELL)\r
                        speech.speakTextInfo(info,reason=speech.REASON_CARET)\r
                else:\r
-                       speech.speakMessage("edge of table")\r
+                       speech.speakMessage(_("edge of table"))\r
 \r
        def script_previousRow(self,keyPress):\r
                info=self.makeTextInfo("caret")\r
                if not info._rangeObj.Information(wdWithInTable):\r
                        speech.speakMessage(_("not in table"))\r
+                       return\r
                if info._moveInTable(0,-1):\r
                        info.updateCaret()\r
                        info.expand(textInfos.UNIT_CELL)\r
                        speech.speakTextInfo(info,reason=speech.REASON_CARET)\r
                else:\r
-                       speech.speakMessage("edge of table")\r
+                       speech.speakMessage(_("edge of table"))\r
 \r
        def script_nextColumn(self,keyPress):\r
                info=self.makeTextInfo("caret")\r
                if not info._rangeObj.Information(wdWithInTable):\r
                        speech.speakMessage(_("not in table"))\r
+                       return\r
                if info._moveInTable(1,0):\r
                        info.updateCaret()\r
                        info.expand(textInfos.UNIT_CELL)\r
                        speech.speakTextInfo(info,reason=speech.REASON_CARET)\r
                else:\r
-                       speech.speakMessage("edge of table")\r
+                       speech.speakMessage(_("edge of table"))\r
 \r
        def script_previousColumn(self,keyPress):\r
                info=self.makeTextInfo("caret")\r
                if not info._rangeObj.Information(wdWithInTable):\r
                        speech.speakMessage(_("not in table"))\r
+                       return\r
                if info._moveInTable(-1,0):\r
                        info.updateCaret()\r
                        info.expand(textInfos.UNIT_CELL)\r
                        speech.speakTextInfo(info,reason=speech.REASON_CARET)\r
                else:\r
-                       speech.speakMessage("edge of table")\r
+                       speech.speakMessage(_("edge of table"))\r
 \r
 [WordDocument.bindKey(keyName,scriptName) for keyName,scriptName in [\r
        ("control+alt+extendedUp","previousRow"),\r
index 8924f2e..4c354ea 100644 (file)
@@ -73,6 +73,8 @@ Notable features of this release include greatly simplified object navigation; v
 - The URL of the document and "MSAAHTML Registered Handler" are no longer sometimes spuriously reported in Internet Explorer and other MSHTML controls. (#811)\r
 - In tree views in the Eclipse IDE, the previously focused item is no longer incorrectly announced when focus moves to a new item.\r
 - NVDA now functions correctly on a system where the current working directory has been removed from the DLL search path (by setting the CWDIllegalInDllSearch registry entry to 0xFFFFFFFF). Note that this is not relevant to most users. (#907)\r
+- When the table navigation commands are used outside of a table in Microsoft Word, "edge of table" is no longer spoken after "not in table". (#921)\r
+- When the table navigation commands cannot move due to being at the edge of a table in Microsoft Word, "edge of table" is now spoken in the configured NVDA language rather than always in English. (#921)\r
 \r
 \r
 = 2010.1 =\r