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

Disable text style navigation in Kindle #16559

Closed
Adriani90 opened this issue May 16, 2024 · 3 comments · Fixed by #16571
Closed

Disable text style navigation in Kindle #16559

Adriani90 opened this issue May 16, 2024 · 3 comments · Fixed by #16571
Milestone

Comments

@Adriani90
Copy link
Collaborator

Detailed description of the issue

Text style navigation does not work in Kindle for Desktop because text formating is not available in Kindle. Instead, the text style navigation fails and produces errors and freezes of at least 1.5 seconds while trying to get text style formatting.

Why are the other templates not appropriate in this case?

It is not a bug, it is a limitation given by Kindle, so we should not support text style navigation there.
This request is also the oposite of a feature.

Have you asked for advice on how to report this issue via a community discussion? If so, please link to the discussion

n/a

Steps to reproduce or illustrate the issue (if applicable)

  1. Open NVDA
  2. Assign [ and shift+[ for different style navigation
  3. Assign ] and shift+] for same style navigation
  4. Open a book in Kindle for desktop
  5. Press the assigned commands for navigating to next and previous text styles

Expected outcome or behaviour (if applicable)

NVDA should not support text style navigation because formatting information is not available.

Screenshots, logs, and other attachments (if applicable)

n/a

System configuration or software environment (if applicable)

n/a

Additional information (if applicable)

Following is written to the log:

IO - inputCore.InputManager.executeGesture (20:17:50.672) - winInputHook (4440):
Input: kb(laptop):plus
DEBUGWARNING - NVDAObjects.IAccessible.IAccessible._get_IA2States (20:17:50.672) - MainThread (8124):
could not get IAccessible2 states
Traceback (most recent call last):
  File "NVDAObjects\IAccessible\__init__.pyc", line 1922, in _get_IA2States
_ctypes.COMError: (-2147467263, 'Nicht implementiert', (None, None, None, 0, None))
DEBUGWARNING - NVDAObjects.IAccessible.IA2TextTextInfo._getLineOffsets (20:17:50.952) - MainThread (8124):
IAccessibleText::textAtOffset failed
Traceback (most recent call last):
  File "NVDAObjects\IAccessible\__init__.pyc", line 376, in _getParagraphOffsets
  File "comtypes\_memberspec.pyc", line 482, in __call__
_ctypes.COMError: (-2147024809, 'Falscher Parameter.', (None, None, None, 0, None))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "NVDAObjects\IAccessible\__init__.pyc", line 349, in _getLineOffsets
  File "comtypes\_memberspec.pyc", line 482, in __call__
_ctypes.COMError: (-2147024809, 'Falscher Parameter.', (None, None, None, 0, None))
DEBUG - watchdog._waitUntilNormalCoreAliveTimeout (20:17:51.183) - watchdog (7464):
Potential freeze, waiting up to 10 seconds.
ERROR - scriptHandler.executeScript (20:17:52.102) - MainThread (8124):
error executing script: <bound method BrowseModeTreeInterceptor.addQuickNav.<locals>.<lambda> of <appModules.kindle.BookPageViewTreeInterceptor object at 0x09033DD0>> with gesture 'plus'
Traceback (most recent call last):
  File "scriptHandler.pyc", line 295, in executeScript
  File "browseMode.pyc", line 558, in <lambda>
  File "browseMode.pyc", line 516, in _quickNavScript
  File "browseMode.pyc", line 2447, in _iterTextStyle
IndexError: list index out of range
DEBUG - watchdog._waitUntilNormalCoreAliveTimeout (20:17:52.184) - watchdog (7464):
Recovered from potential freeze after 1.5018194999993284 seconds.
IO - inputCore.InputManager.executeGesture (20:17:52.659) - winInputHook (4440):
Input: kb(laptop):ü
DEBUGWARNING - NVDAObjects.IAccessible.IAccessible._get_IA2States (20:17:52.664) - MainThread (8124):
could not get IAccessible2 states
Traceback (most recent call last):
  File "NVDAObjects\IAccessible\__init__.pyc", line 1922, in _get_IA2States
_ctypes.COMError: (-2147467263, 'Nicht implementiert', (None, None, None, 0, None))
DEBUGWARNING - NVDAObjects.IAccessible.IA2TextTextInfo._getLineOffsets (20:17:52.942) - MainThread (8124):
IAccessibleText::textAtOffset failed
Traceback (most recent call last):
  File "NVDAObjects\IAccessible\__init__.pyc", line 376, in _getParagraphOffsets
  File "comtypes\_memberspec.pyc", line 482, in __call__
_ctypes.COMError: (-2147024809, 'Falscher Parameter.', (None, None, None, 0, None))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "NVDAObjects\IAccessible\__init__.pyc", line 349, in _getLineOffsets
  File "comtypes\_memberspec.pyc", line 482, in __call__
_ctypes.COMError: (-2147024809, 'Falscher Parameter.', (None, None, None, 0, None))
DEBUG - watchdog._waitUntilNormalCoreAliveTimeout (20:17:53.159) - watchdog (7464):
Potential freeze, waiting up to 10 seconds.
IO - speech.speech.speak (20:17:55.102) - MainThread (8124):
Speaking ['No next different style text']
DEBUG - watchdog._waitUntilNormalCoreAliveTimeout (20:17:55.161) - watchdog (7464):
Recovered from potential freeze after 2.501913500000228 seconds.
@Adriani90
Copy link
Collaborator Author

cc: @mltony, @seanbudd slowly I think the whole text style navigation feature should only be available in browsers, and not in other browse mode documents. It produces too many issues and it is not stable at all.

@CyrilleB79
Copy link
Collaborator

Style navigation, and maybe also other types of navigation implemented by @mltony, should be tested in all type of content where the shortcut can be executed, I.e. all content having a browse mode I guess.

PS: Not very important, but IMO, the bug template was suitable for this. It's a bug: text style navigation feature is expected to work in any text content but it does not actually work in Kindle. No worry though: with this template, the required information is available in any case.

@Adriani90
Copy link
Collaborator Author

Adriani90 commented May 16, 2024 via email

@seanbudd seanbudd added this to the 2024.2 milestone May 20, 2024
seanbudd pushed a commit that referenced this issue May 20, 2024
Closes #16559
Closes #16558

Summary of the issue:
Fancy QuickNav commands (style navigation, text navigation, vertical navigation) don't work correctly in Kindle desktop app.

Description of user facing changes
Fancy quickNav commands will be disabled in Kindle.

Description of development approach
Throwing a NotImplementedException.
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.

3 participants