• R/O
  • HTTP
  • SSH
  • HTTPS

nvdajp: 提交

NVDA with Japanese branch


Commit MetaInfo

修订版bf7aa0f97f6dc0495054a90007c76dc043473557 (tree)
时间2013-06-06 22:17:38
作者Takuya Nishimoto <nishimotz@gmai...>
CommiterTakuya Nishimoto

Log Message

experimental work regarding Excel cell range announcement (ti31413)

更改概述

差异

--- a/source/NVDAObjects/window/excel.py
+++ b/source/NVDAObjects/window/excel.py
@@ -309,6 +309,20 @@ class ExcelSelection(ExcelBase):
309309 def _get_name(self):
310310 firstCell=self.excelRangeObject.Item(1)
311311 lastCell=self.excelRangeObject.Item(self.excelRangeObject.Count)
312+ # nvdajp begin
313+ # if count of cells is less than or equals 6, use their contents.
314+ if self.excelRangeObject.Count <= 6:
315+ items = []
316+ for p in xrange(1, self.excelRangeObject.Count + 1):
317+ c = self.excelRangeObject.Item(p).Text or _("empty")
318+ items.append(c)
319+ items.append(_("{firstAddress} through {lastAddress}").format(firstAddress=self.getCellAddress(firstCell),lastAddress=self.getCellAddress(lastCell)))
320+ return u' '.join(items)
321+ # if there are more than 6 cells, use first cell, last cell, and the count of cells.
322+ c1 = firstCell.Text or _("empty")
323+ c2 = lastCell.Text or _("empty")
324+ return _("{firstAddress} {firstContent} through {lastAddress} {lastContent} count {cellCount}").format(firstAddress=self.getCellAddress(firstCell),firstContent=c1,lastAddress=self.getCellAddress(lastCell),lastContent=c2,cellCount=self.excelRangeObject.Count)
325+ # nvdajp end
312326 # Translators: This is presented in Excel to show the current selection, for example 'a1 c3 through a10 c10'
313327 return _("{firstAddress} {firstContent} through {lastAddress} {lastContent}").format(firstAddress=self.getCellAddress(firstCell),firstContent=firstCell.Text,lastAddress=self.getCellAddress(lastCell),lastContent=lastCell.Text)
314328
--- a/source/locale/ja/LC_MESSAGES/nvda.po
+++ b/source/locale/ja/LC_MESSAGES/nvda.po
@@ -219,6 +219,18 @@ msgstr "日本語6点情報処理点字"
219219 msgid "%s:%s"
220220 msgstr "%s時%s分"
221221
222+#: NVDAObjects/window/excel.py:318
223+msgid "empty"
224+msgstr "空白"
225+
226+#: NVDAObjects/window/excel.py:320
227+msgid "{firstAddress} through {lastAddress}"
228+msgstr "{firstAddress}から{lastAddress}"
229+
230+#: NVDAObjects/window/excel.py:322
231+msgid "{firstAddress} {firstContent} through {lastAddress} {lastContent} count {cellCount}"
232+msgstr "{firstContent} {firstAddress}から {lastContent} {lastAddress} {cellCount}セル"
233+
222234 # end of nvdajp
223235
224236 #: globalCommands.py:880
Show on old repository browser