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

Add "Only in edit controls" mode for typing echo #17505

Open
wants to merge 6 commits into
base: master
Choose a base branch
from

Conversation

cary-rowen
Copy link
Contributor

Link to issue number:

Fixes #16848, related #10331, #3027

Summary of the issue:

Currently NVDA can only toggle typing echo (characters and words) on or off globally. Users want more granular control to only have typing feedback in edit controls, while keeping it off in other contexts like listss or non-edit areas.

Description of user facing changes

  • Added a new option "Only in edit controls" for both "Speak typed characters" and "Speak typed words" settings in Keyboard Settings
  • Instead of checkboxes, these are now combo boxes with three options:
    • Off: No typing echo
    • On: Echo all typed text
    • Only in edit controls: Only echo text typed in edit fields
  • Updated relevant documentation in the user guide

Description of development approach

The implementation:

  1. Added a TypingEcho enum in configFlags.py with values:
    • OFF (0)
    • ON (1)
    • EDIT_CONTROLS (2)
  2. Changed keyboard typing echo configuration from boolean to integer values
  3. Updated speech.py, behaviors.py and inputComposition.py to use the new enum
  4. Modified settings dialog to use combo box instead of checkbox
  5. Updated documentation

Testing strategy:

Tested the following scenarios:

  1. Basic functionality:
  • Open Notepad (edit control)
    • Set to "Only in edit controls"
    • Type text - should be announced
    • Verify both character and word echo settings
  • Explorer file lists(non-edit control)
    • Type text - should not be announced
  • Test all three modes (Off, On, Only in edit controls)
  1. Different contexts:
  • Web browser input fields
  • Rich text editors
  • Read-only text areas
  • Terminal windows

Known issues with pull request:

None identified.

Code Review Checklist:

  • Documentation:
    • Change log entry
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English
  • API is compatible with existing add-ons.
  • Security precautions taken.

@coderabbitai summary

@cary-rowen cary-rowen marked this pull request as draft December 11, 2024 23:28
@Adriani90
Copy link
Collaborator

Great work on this, thank you.

@Adriani90
Copy link
Collaborator

I think this needs a changelog entry as well.

@AppVeyorBot
Copy link

  • PASS: Translation comments check.
  • PASS: License check.
  • PASS: Unit tests.
  • FAIL: Lint check. See test results and lint artifacts for more information.
  • PASS: System tests (tags: installer NVDA).
  • Build (for testing PR): https://ci.appveyor.com/api/buildjobs/2b1503020gqhri7g/artifacts/output/l10nUtil.exe nvda_snapshot_pr17505-34744,8a5bed98.exe
  • CI timing (mins):
    INIT 0.0,
    INSTALL_START 1.2,
    INSTALL_END 0.9,
    BUILD_START 0.0,
    BUILD_END 25.6,
    TESTSETUP_START 0.0,
    TESTSETUP_END 0.3,
    TEST_START 0.0,
    TEST_END 18.7,
    FINISH_END 0.1

See test results for failed build of commit 8a5bed9868

@cary-rowen cary-rowen marked this pull request as ready for review December 12, 2024 03:33
@AppVeyorBot
Copy link

  • PASS: Translation comments check.
  • PASS: License check.
  • PASS: Unit tests.
  • FAIL: Lint check. See test results and lint artifacts for more information.
  • PASS: System tests (tags: installer NVDA).
  • Build (for testing PR): https://ci.appveyor.com/api/buildjobs/8dcauldlcfjvaodn/artifacts/output/l10nUtil.exe nvda_snapshot_pr17505-34752,259e6d54.exe
  • CI timing (mins):
    INIT 0.0,
    INSTALL_START 1.2,
    INSTALL_END 0.9,
    BUILD_START 0.0,
    BUILD_END 24.6,
    TESTSETUP_START 0.0,
    TESTSETUP_END 0.3,
    TEST_START 0.0,
    TEST_END 18.6,
    FINISH_END 0.2

See test results for failed build of commit 259e6d5452

@CyrilleB79
Copy link
Collaborator

Very nice addition @cary-rowen! Thanks.

I have some questions:

  1. Shouldn't there be a config upgrade? I.e. a value in the old config should remain in the new one.
  2. I think that "Only in edit controls" should become the default behaviour; I guess that most people would be happy and moreover, it's a security fix as described in NVDA reading out words it shouldn't if 'speak typed words' is on #10331.
  3. If NV Access reviewers (@SaschaCowley or @seanbudd) do not accept the new behaviour to be the default for now, should we use a feature flag to be able to change the default in the future?
  4. With the new option, can typing be heard when typing in an edit field but when text is not actually written, e.g.:
    • In cmd, when initiating an ssh connection, typing the password outputs no visible character
    • In a read-only edit field, e.g. the synth field of NVDA speech settings panel.

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 this pull request may close these issues.

Speak typed characters and words applied to edit fields only.
4 participants