-
-
Notifications
You must be signed in to change notification settings - Fork 662
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
Say all, move caret per word instead of per line/sentence #9937
Conversation
Wrong branche? |
@DrSooom: Could you elaborate? |
"nvaccess:master" instead of "nvaccess:threshold". Compare with PR #9946. |
that's intentional. This won't go into master before threshold is merged.
|
GitHub still shows 145 commits for this PR after Threshold was merged into Master. Keep an eye on it. (I thought that GitHub respectively git would be more intelligent.) |
Interesting. I intended to rebase it. May be I did something wrong. thanks for pointing uit.
|
…ultiple sentences
Issue should now be fixed. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Increase caret updates during say all sounds wordy to me. How about "Move cursor by word during say all"
source/config/configSpec.py
Outdated
@@ -37,6 +37,7 @@ | |||
outputDevice = string(default=default) | |||
autoLanguageSwitching = boolean(default=true) | |||
autoDialectSwitching = boolean(default=false) | |||
increaseSayAllCaretUpdates = boolean(default=false) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be a speech synth dependent setting? For example, users may have many synths, and some might work better with this feature than others.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@derekriemer wrote:
Increase caret updates during say all sounds wordy to me. How about "Move cursor by word during say all"
Because while the caret is intended to move per word, the movement is also limited to once per half a second.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ugh, sorry for the comment above, it ended up at the wrong place.
Anyway, making this a per synth setting makes sense to me. I will do that.
source/speech/commands.py
Outdated
@@ -253,12 +260,27 @@ class CallbackCommand(BaseCallbackCommand): | |||
otherwise it will block production of further speech and or other functionality in NVDA. | |||
""" | |||
|
|||
def __init__(self, callback): | |||
def __init__(self, callback: Union[SUPPORTED_CALLBACK_TYPES]): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is a class with a call supported by this union?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No. The only way to acoomplish this seems to be the use of collections.abc.Callable, but that also applies to classes itself. I'm reluctant to do this.
Fixed typo Co-Authored-By: Derek Riemer <[email protected]>
Co-Authored-By: Derek Riemer <[email protected]>
PR introduces Flake8 errors 😲 See test results for Failed build of commit 23b707621c |
…is code from 2017 and later
No.
…On Mon, Aug 5, 2019 at 5:20 AM Leonard de Ruijter ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In source/config/configSpec.py
<#9937 (comment)>:
> @@ -37,6 +37,7 @@
outputDevice = string(default=default)
autoLanguageSwitching = boolean(default=true)
autoDialectSwitching = boolean(default=false)
+ increaseSayAllCaretUpdates = boolean(default=false)
@derekriemer <https://github.com/derekriemer> wrote:
Increase caret updates during say all sounds wordy to me. How about "Move
cursor by word during say all"
Because while the caret is intended to move per word, the movement is also
limited to once per half a second.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#9937?email_source=notifications&email_token=ABI2FPP2C5AH6ZWBVU5GN6TQDAEIPA5CNFSM4IEDJ4KKYY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOCARKAEI#discussion_r310556034>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/ABI2FPLVUTNWTSXDPSL6HYDQDAEIPANCNFSM4IEDJ4KA>
.
--
Derek Riemer: Improving the world one byte at a time!
- University of Colorado Boulder Department of computer science, 4th
year undergraduate student.
- Accessibility enthusiast.
- Proud user of the NVDA screen reader.
- Open source enthusiast.
- Skier.
Personal website <http://derekriemer.com>
|
It starts with _, so it's probably fine.
On Sat, Aug 10, 2019 at 3:19 AM Derek Scott Riemer <
[email protected]> wrote:
… No.
On Mon, Aug 5, 2019 at 5:20 AM Leonard de Ruijter <
***@***.***> wrote:
> ***@***.**** commented on this pull request.
> ------------------------------
>
> In source/config/configSpec.py
> <#9937 (comment)>:
>
> > @@ -37,6 +37,7 @@
> outputDevice = string(default=default)
> autoLanguageSwitching = boolean(default=true)
> autoDialectSwitching = boolean(default=false)
> + increaseSayAllCaretUpdates = boolean(default=false)
>
> @derekriemer <https://github.com/derekriemer> wrote:
>
> Increase caret updates during say all sounds wordy to me. How about "Move
> cursor by word during say all"
>
> Because while the caret is intended to move per word, the movement is
> also limited to once per half a second.
>
> —
> You are receiving this because you were mentioned.
> Reply to this email directly, view it on GitHub
> <#9937?email_source=notifications&email_token=ABI2FPP2C5AH6ZWBVU5GN6TQDAEIPA5CNFSM4IEDJ4KKYY3PNVWWK3TUL52HS4DFWFIHK3DMKJSXC5LFON2FEZLWNFSXPKTDN5WW2ZLOORPWSZGOCARKAEI#discussion_r310556034>,
> or mute the thread
> <https://github.com/notifications/unsubscribe-auth/ABI2FPLVUTNWTSXDPSL6HYDQDAEIPANCNFSM4IEDJ4KA>
> .
>
--
Derek Riemer: Improving the world one byte at a time!
- University of Colorado Boulder Department of computer science, 4th
year undergraduate student.
- Accessibility enthusiast.
- Proud user of the NVDA screen reader.
- Open source enthusiast.
- Skier.
Personal website <http://derekriemer.com>
--
Derek Riemer: Improving the world one byte at a time!
- University of Colorado Boulder Department of computer science, 4th
year undergraduate student.
- Accessibility enthusiast.
- Proud user of the NVDA screen reader.
- Open source enthusiast.
- Skier.
Personal website <http://derekriemer.com>
|
PR introduces Flake8 errors 😲 See test results for Failed build of commit ada9083620 |
I wrote this pull request on behalf of @BabbageCom. As I'm leaving @BabbageCom after the 29th of November, I can no longer afford maintaining this pr other than applying very basic review actions. If this pull request requires major changes, they will have to be applied by someone else, e.g. @sjfbol or whoever else is willing to take it. |
See test results for failed build of commit 20cf56ec97 |
See test results for failed build of commit 4092c7d318 |
It would be worth considering how "vision enhancement providers" fit into this. It would be good if focus highlight followed the current word being spoken. |
I agree, though that might be something more suitable for a follow up pr.
|
This has merge conflicts. I'm currently in a situation where I neither have the time nor interest to fix them, it just requires too much attention and thorough testing. Apart from @BabbageCom, is there anyone who think this change would be a huge benefit and can take this over? |
cc: @Andre9642, @CyrilleB79, @JulienCochuyt Imo this would bring some benefits for braille users but also for people using focus highlighting. |
This is certainly something I would be interested in working on. I have a vague plan to use a mechanism like this to improve the speech viewer. I don't think I can prioritize this immediately, so if anyone else has capacity and interest, feel free to take it on. But if not, we will get to this eventually. 😄 |
I can take it. What is the procedure? Should I create yet another PR? |
Yes, thanks @dawidpieper. Make a copy of this branch, and create a new PR from that branch, comment on this PR with the new PR number and I'll close this one. That will make it clear to everyone that you intend to take over the development. |
Closing as superseded by #11658 |
Link to issue number:
Fixes #9179
Fixes #3287
Summary of the issue:
When using say all, the caret moves per sentence or per line, not per word. This is not very helpful when using magnification or braille to track the current position of say all. More importantly though, when reviewing text with say all, exiting say all makes you end up at the start of the line or sentence, not at the current word's position.
Say all also doesn't follow in browse mode.
Description of how this pull request fixes the issue:
Find white space using regex, and bring the caret to it accordingly. This avoids fetching text info per word, which can be pretty expensive.
This option can be found in the speech settings: "Increase caret updates during say all"
Testing performed:
Tested in Word, Notepad and browse mode that the caret follows read words. Note that there is a minimal 0.5 seconds interval between every caret update to avoid the caret going mad on higher speechrates.
Known issues with pull request:
Change log entry: