Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to implement fake table navigation in a list #10864

Closed
CyrilleB79 opened this issue Mar 10, 2020 · 5 comments · Fixed by #10868
Closed

Unable to implement fake table navigation in a list #10864

CyrilleB79 opened this issue Mar 10, 2020 · 5 comments · Fixed by #10868
Milestone

Comments

@CyrilleB79
Copy link
Collaborator

Steps to reproduce:

In my Outlook Extended add-on V1.4, I have implemented fake table navigation in the address book results list by creating a custom class inheriting from RowWithoutCellObjects and RowWithFakeNavigation from behaviors.py.
This class implements the required method _getColumnContent as well as the optional method _getColumnHeader.
This was working with NVDA 2019.2 as well as with early Py3 alpha versions. However, this feature was broken in NVDA 2019.3.
Although documented as optional, I have had to implement _getColumnLocation to fix the issue (fixed in V1.5).

Actual behavior:

RowWithoutCellObjects._getColumnLocation is documented as optional in behaviors.py

Expected behavior:

RowWithoutCellObjects._getColumnLocation implementation in subclasses should be documented as mandatory.

An other alternative would be not to add INVISIBLE state to a _FakeTableCell if _FakeTableCell._get_location does not return a location (i.e. returns None). I do not know however how the navigator object highlight would behave in this case.

Technical background

This doc mismatch was introduced with the following commit:

Author: Leonard de Ruijter <leonardder@users.noreply.github.com>
Date:   Tue Sep 17 09:11:21 2019 +0200
    Hide invisible columns in syslistview32 lists (#9873)

System configuration

NVDA installed/portable/running from source:

installed

NVDA version:

2019.3.1

Windows version:

10

Name and version of other software in use when reproducing the issue:

N/A

Other information about your system:

N/A

Other questions

Does the issue still occur after restarting your computer?

yes

Have you tried any other versions of NVDA? If so, please report their behaviors.

Yes. NVDA2019.2.1 is OK.

If addons are disabled, is your problem still occuring?

N/A

Did you try to run the COM registry fixing tool in NVDA menu / tools?

N/A

@CyrilleB79
Copy link
Collaborator Author

I did not yet provide a PR to fix this because I would like to agree on what should be implemented: change RowWithoutCellObjects._getColumnLocation documentation to so that its implementation should be mandatory or change _FakeTableCell._get_state implementation.

@LeonarddeR, since you have implemented the commit, could you provide feedback on the alternative you would prefer? You could also comment on the nav object highlight question.
Thanks

@josephsl
Copy link
Collaborator

josephsl commented Mar 10, 2020 via email

@LeonarddeR
Copy link
Collaborator

Ugh, this side effect was unintended. I think a solution should be among the lines of:uggest

  • Change the _get_states impl as you suggested. If location is None, hasIrrelevantLocation is true and the highlighter should ignore it.
  • I actually think that the default of beTransparentToMouse should be hasIrrelevantLocation, since the mouse could never be on those objects.

@CyrilleB79
Copy link
Collaborator Author

Yes, after studying a little more the issue:
Since RowWithoutCellObjects is inheriting from NVDAObject and NVDAObject is allowed not to define location, it is clear that the RowWithoutCellObjects._getColumnLocation method redefinition should remain optional:

  1. if .location is defined, nav object
  2. if .location is None, no nav object highlighter should appear or it should appear only around the full table row
    Moreover, if .location is defined and the column width is 0, I would expect that the nav obj highlighter appear around this fake table cell when obj navigating to it. Of course this cell should remain a skipped cell when using control+alt+arrows commands.
    Do you agree?

You write:

I actually think that the default of beTransparentToMouse should be hasIrrelevantLocation, since the mouse could never be on those objects

Not sure to understand what you mean and how beTransparentToMouse is working. At which level do you suggest this change? Only in fake cells or for any NVDAObject?

@CyrilleB79
Copy link
Collaborator Author

We may follow this discussion in the PR (#10868) since we are already talking of code details.

@nvaccessAuto nvaccessAuto added this to the 2020.1 milestone Mar 17, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants