Skip to content

Add mouse to view magnifier command#20238

Merged
seanbudd merged 7 commits into
nvaccess:masterfrom
CyrilleB79:magMoveCommands
Jun 3, 2026
Merged

Add mouse to view magnifier command#20238
seanbudd merged 7 commits into
nvaccess:masterfrom
CyrilleB79:magMoveCommands

Conversation

@CyrilleB79

@CyrilleB79 CyrilleB79 commented May 28, 2026

Copy link
Copy Markdown
Contributor

Link to issue number:

Closes #20127

Summary of the issue:

A command (script) to move the mouse cursor in the center of the magnified view was requested.

Description of user facing changes:

An unassigned command (script) to move the mouse cursor in the center of the magnified view has been added.

For now, the command remains unassigned, taking into account that many NVDA users won't use Magnifier at all and that too many magnifier key assignments for Magnifier may create many unused default gestures for them.

The command can operate even if a mouse button is active so that this command can be used for dragging actions.

Description of developer facing changes:

N/A

Description of development approach:

Factorise common code with the _keepMouseCentered method, and keep the specific part related to mouse button locking support separated.

Testing strategy:

  • Manual test:
    • Move mouse to center of the view
    • Also checked that I could use this command during a drag & drop operation (moving a file in Windows Explorer), locking and unlocking mouse button with NVDA specific keyboard commands.
  • Added unit tests for this commend

Known issues with pull request:

None

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.

@CyrilleB79 CyrilleB79 marked this pull request as ready for review May 28, 2026 21:28
@CyrilleB79 CyrilleB79 requested review from a team as code owners May 28, 2026 21:28
@CyrilleB79

Copy link
Copy Markdown
Contributor Author

Note: PR against beta since:

  • the code of this PR is quite small / localized
  • we are still in early beta phase (no beta version released yet)
  • increasing usability of Magnifier from its first release is the key for its success / adoption

If you prefer me to open this PR against master, let me know and I will rebase. Thanks.

@seanbudd seanbudd changed the base branch from beta to master May 29, 2026 01:40

@seanbudd seanbudd left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @CyrilleB79 - I've retargeted to master.
Can you please add a change log entry for 2026.3?

Comment thread source/_magnifier/utils/types.py Outdated
@CyrilleB79

Copy link
Copy Markdown
Contributor Author

@seanbudd the PR is ready again. I have:

  • Upmerged from master
  • Added a change log item
  • Slightly reworded the input help of the command ("to the center" seems more natural than "in the center")

@seanbudd seanbudd added the conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review. label Jun 1, 2026
@Boumtchack Boumtchack mentioned this pull request Jun 2, 2026
5 tasks
seanbudd pushed a commit that referenced this pull request Jun 3, 2026
fixes #20200
fixes #20195
Summary of the issue:

The option to keep mouse centered on the screen was originally my idea but is bringing more nuisance, and not much use.
As talked with @CyrilleB79, the best solution would be to remove it and replace this idea with the gesture that he worked on #20238
Description of user facing changes:

won't be able to keep mouse centered on the screen anymore
Description of developer facing changes:

Keep mouse centered options/functions/variables/tests have been removed
@seanbudd

seanbudd commented Jun 3, 2026

Copy link
Copy Markdown
Member

@CyrilleB79 - could you please resolve merge conflicts?

@Qchristensen Qchristensen left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reads well

@CyrilleB79

Copy link
Copy Markdown
Contributor Author

@seanbudd I have fixed conflicts.

@seanbudd seanbudd merged commit 197a0d1 into nvaccess:master Jun 3, 2026
17 checks passed
@github-actions github-actions Bot added this to the 2026.3 milestone Jun 3, 2026
@CyrilleB79 CyrilleB79 deleted the magMoveCommands branch June 4, 2026 09:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

conceptApproved Similar 'triaged' for issues, PR accepted in theory, implementation needs review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Magnifier - Add commands to move the mouse in the center of the magnified view

3 participants