nvaccess / nvda

NVDA, the free and open source Screen Reader for Microsoft Windows
https://www.nvaccess.org/
Other
2.12k stars 638 forks source link

Ref.: bug #3563. Incorrect cell address is announced when moving column wise in extended selection mode #5313

Open nvaccessAuto opened 9 years ago

nvaccessAuto commented 9 years ago

Reported by sumandogra on 2015-08-26 09:59 Excel 2013 Reference bug #3563. When one navigates in columns with LEFT/RIGHT ARROW in extended selection mode on with F8, the cell coordinates are not announced correctly. The row coordinates are announced instead of the column coordinates when one is navigating in the columns.

Steps to reproduce:

  1. Install the test build of NVDA.
  2. Press F8 to put on the extended selection mode.
  3. Start selecting row wise with UP/DOWN ARROW.
  4. The cells are selected.
  5. Now use, LEFT/RIGHT ARROW to select the adjacent cells from adjacent columns. The cell coordinates are announced incorrectly. Instead of announcing the coordinates for the columns, the row coordinates are announced.
nvaccessAuto commented 9 years ago

Comment 1 by manshulvbelani on 2015-09-29 10:26 The code for this issue is available in branch in_t5313 at url: ​https://bitbucket.org/manish_agrawal/nvda

Also there is an alternate approach possible.Instead of taking the address of selection, we can get the number of blocks selected using selection.areas.count and then for each area we can get the address and content of first and last cell of that particular area/block. The code snippet for this alternate approach is given below:

text"" selection=self.excelRangeObject selectedBlocksCount=selection.Areas.Count for item in range(1,selectedBlocksCount+1): firstCellAddress=self.excelRangeObject.Areas(item).Cells(1,1).Address(False,False,xlA1,False) lastCellAddress=self.excelRangeObject.Areas(item).Cells(selection.Areas(item).Rows.Count, selection.Areas(item).Columns.Count).Address(False,False,xlA1,False) firstCellContent=self.excelRangeObject.Areas(item).Cells(1,1).Text lastCellContent=self.excelRangeObject.Areas(item).Cells(selection.Areas(item).Rows.Count, selection.Areas(item).Columns.Count).Text text+= _("{firstAddress} {firstContent} through {lastAddress} {lastContent} ").format(firstAddress=firstCellAddress,firstContent=firstCellContent,lastAddress=lastCellAddress,lastContent=lastCellContent) return text

Please review the code and let me know if any changes are required. Thanks!

bhavyashah commented 7 years ago

@michaelDCurran (our resident MS Office accessibility in-charge) Just a friendly reminder to review this almost 2-year-old code submission.

Adriani90 commented 5 years ago

@ManshulBelani is it possible to raise a pull request if this is still an issue? I cannot reproduce it completely in NVDA last Alpha on Windows 10 1809 Update with MS Excel 2016. However, NVDA repeats the first selected cell and the last one twice. If I am on a1 and go to b3 with down and right arrow, NVDA announced "a1 through a1 through b3 through b3". Actually it should only announce "a1 through b3". cc: @michaelDCurran

Adriani90 commented 1 month ago

The extra verbosity as explained in my last comment is also reproducible in MS Excel 365 with NvDA 2024.4 Beta.