Repository: nvaccess/nvda

Issue:
Splitting translatable strings for merged cells makes translation more flexible
### Is your feature request related to a problem? Please describe.
As far as I know, Western users are more accustomed to the reporting method of row xx column xx, but for Chinese users, on the contrary, Chinese users are more accustomed to the method of xx row xx column.
However, for vertical and horizontal merges, they share the same translatable string, which is "through %s"

NVDA reports the following:
* column XX through YY
* row XX through YY

The following is the Chinese translation:
* XX 列到 YY 列
* XX 行到 YY 行

In short, we need to append 'row' or 'column' after the translatable string "through %s".

### Describe the solution you'd like
Splitting translatable strings for merged cells makes translation more flexible
### Describe alternatives you've considered
None
### Additional context
None


Discussion:
@cary-rowen are you a Chinese translator? If yes, could you provide a list of the exact strings to be translated and that cause an issue? This would help to find them. Thanks.


Hi @CyrilleB79 
The translatable strings involved in this issue are as follows:
```
#. Translators: Speaks current row number (example output: row 3).
#, python-format
msgid "row %s"


#. Translators: Speaks the row span added to the current row number (example output: through 5).
#. Translators: Speaks the column span added to the current column number (example output: through 5).
#, python-format
msgid "through %s"

#. Translators: Speaks current column number (example output: column 3).
#, python-format
msgid "column %s"
```


Resolving patch:
diff --git a/source/speech/speech.py b/source/speech/speech.py
--- a/source/speech/speech.py
+++ b/source/speech/speech.py
@@ -1,7 +1,7 @@
 # A part of NonVisual Desktop Access (NVDA)
 # This file is covered by the GNU General Public License.
 # See the file COPYING for more details.
-# Copyright (C) 2006-2022 NV Access Limited, Peter Vágner, Aleksey Sadovoy, Babbage B.V., Bill Dengler,
+# Copyright (C) 2006-2023 NV Access Limited, Peter Vágner, Aleksey Sadovoy, Babbage B.V., Bill Dengler,
 # Julien Cochuyt, Derek Riemer, Cyrille Bougot
 
 """High-level functions to speak information.
@@ -1755,7 +1755,7 @@ def getPropertiesSpeech(  # noqa: C901
 				textList.append(rowNumberTranslation)
 				if rowSpan>1 and columnSpan<=1:
 					# Translators: Speaks the row span added to the current row number (example output: through 5).
-					rowSpanAddedTranslation: str = _("through %s") % (rowNumber + rowSpan - 1)
+					rowSpanAddedTranslation: str = _("through {endRow}").format(endRow=rowNumber + rowSpan - 1)
 					textList.append(rowSpanAddedTranslation)
 			_speechState.oldRowNumber = rowNumber
 			_speechState.oldRowSpan = rowSpan
@@ -1773,7 +1773,7 @@ def getPropertiesSpeech(  # noqa: C901
 				textList.append(colNumberTranslation)
 				if columnSpan>1 and rowSpan<=1:
 					# Translators: Speaks the column span added to the current column number (example output: through 5).
-					colSpanAddedTranslation: str = _("through %s") % (columnNumber + columnSpan - 1)
+					colSpanAddedTranslation: str = _("through {endCol}").format(endCol=columnNumber + columnSpan - 1)
 					textList.append(colSpanAddedTranslation)
 			_speechState.oldColumnNumber = columnNumber
 			_speechState.oldColumnSpan = columnSpan


Test patch: