-
-
Notifications
You must be signed in to change notification settings - Fork 621
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
Feature request: Include Sentence Nav as part of NVDA #8518
Comments
Please use NVDA+ALT-ArrowUp/ArrowDown instead of just ALT+ArrowUp/ArrowDown because otherwise it negatively influences the behaviour of ALT+ArrowDown in some programs like in MuseScore as well as comboboxes in Mozilla Firefox. Quote from my "gestures.ini":
|
This is Tony - the author of SentenceNav.
|
Outlook 2016 uses alt + arrow below to open the options of what to do with attachments. |
At the SightCity 2018 a contributor told me that the screenreader user should never change the hotkey allocations. After he noticed that I'm an advanced user, he said to me that I can do this because I know exactly what I'm doing. (I don't want to name the company here.) @mltony: Please do the following twice – once with your add-on enabled and once without it:
So, please forget JAWS and use the NVDA+ALT-combos because it really isn't necessary in every application to have the ability to read by sentences. Only Alt+ArrowKeys cause to many navigations issues for all NVDA users. CTRL+ArrowKeys and CTRL+ALT+ArrowKeys haven't such negative effects yet (NVDA 2018.1). |
Note that it is very unlikely and even undesirable to add sentence navigation to NVDA for cases other than the review cursor. Therefore, if sentence navigation is added, it will only be added to the review cursor (in which case kb(laptop):NVDA+ALT+upArrow and downArrow make much sense) and browse mode. @feerrenrut and @michaelDCurran, do you have thought about this? |
Well, and the abbreviations has also to be translated into the different languages as well. There are hundreds in German and some of them are written differently in Austrian German (de-AT) like "zB" and "z.B." for "z. B.". @Adriani90: See ÖNORM A 1080 (which seems to be completely stroked since May 1st, 2018) or this PDF file. Only the abbreviations ending with a dot are important here. Sadly this PDF file isn't complete. The following are missing based on my quick look: Mo., Di., Mi., Do., Fr., Sa., So., Hr., Hrn., abzügl., bspw., bzgl., bzw., gem., Jhd., lit., o.ä., o. ä., od., o.g., o. g., u.U., u. U., u.a. (without the space), Z. and maybe even many more. [Update: 01:40 CEST): Tsd., Mio., Mrd., tägl., wöchentl., monatl., jährl., inkl. and exkl. |
Re Leonard's comment: Note that it is very unlikely and even undesirable to add sentence navigation to NVDA for cases other than the review cursor. The Sentence Nav add-on is not restricted to review cursor and, in my experience, it is its general availability that makes it so valuable. Re the key combination, the only case so far where I have had to use the bypass is when saving attachments in Outlook. Having installed the add-on, it was immediately obvious that there would be a keyboard clash. It may not be as obvious to some users if the feature was part of NVDA upon installation (especially those who do not read manuals [smile]). But before getting bogged down in which key combination to use, a decision needs to be made as to whether the feature should be included as a core component of NVDA. While it is my view that people should not have to use an add-on to read by such a fundamental unit, that is not my call. |
Okay, I seem to be outgunned here, I can change the keystrokes to NVDA+Alt+Arrows.
For the record, I still disagree that this is right decision. I agree to make the change, but I still need to address all your points here.
|
Oh, and I forgot the most important one.
|
@mltony, I guess alt+arrow keys is still the best option for this. ctrl+alt+arrow keys can for example change the screen orientation in MS Excel or in other applications. NVDA+Alt+arrow keys is also used in indentnav. Right? In my opinion, the best way would be to lock sentencenav in such a way that NVDA reads automatically by sentence when pressing up and down arrow key. That means, NVDA would not read one line but one sentence. The keystroke to lock sentencenav could be something like pressing ctrl, shift, ctrl in this order. To unlock it you could press shift, ctrl, shift. In any case this add-on should be part of NVDA's core as soon as the key conflicts are solved. |
Guys, let's turn the discussion in the right way. We can discuss about NVDA and Jaws on the mail list if needed. We want to find the best way to work productively with NVDA and a comparison with Jaws is not the what we want to end up with. |
@Adriani90: I see that including this feature into the settings ring could be useful for some users. But your recommendation about locking and unlocking with CTRL » Shift » CTRL is much too complex for non-advanced NVDA users – and inefficient as well because you have to press too many keys just for using a single function. |
As for whether sentence navigation should be a part of NVDA core - you guys should decide. I am obviously biased, I missed this feature a lot when I switched to NVDA and it is extremely important to me. I find it especially useful when reading scientific papers or articles, where I need to repeat every sentence multiple times. In this case if I'm left with line navigation, my brain has to keep diverging some share of attention away from the topic of the article just to reconstruct the boundaries of the sentences. |
|
Alt+upArrow and alt+downArrow both are shortcuts used in applications for sentence navigation. Note that in these cases (e.g. MS Word), the application itself is responsible for the sentence navigation. The only reason why NVDA reads by sentence in MS Word is because Word moves the cursor and NVDA reflects that behaviour with speech. Update: it turns out that my assumption was wrong, see also #8541 3288 |
Where can I get this addon
…On 19/07/2018 12:23 p. m., mltony wrote:
This is Tony - the author of SentenceNav.
1. My main reason to use Alt+Up/Down arrow is to make this shortcut
consistent with Jaws. We probably don't want to make Jaws to NVDA
transition harder by defining too many new keyboard shortcuts to
learn.
2. Alt+Up/Down arrows on the combo boxes should not be affected in
any application. When either of these keystrokes is issued, I
check for the currently focused element and if it happens to be a
combo box, I issue gesture.send() to have this keystroke be
processed by the operating system.
3. Some other applications might indeed be affected by Alt+Up/Down
shortcut being Overridden. But the same can be said about
Control+UpDown arrows. In fact the same can be said about any NVDA
shortcut that doesn't involve NVDA key. In this case I can argue
that a potential workaround is to have the user to customize the
keystroke in the configuration to avoid the conflict.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#8518 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/API6eah5XsLTbqfSggG90tDSOGrHYnwHks5uIM6EgaJpZM4VVy1H>.
|
|
Wow, my apologies there. I really was quite sure that this was Word functionality, but #3288 turns out that this is NVDA specific indeed. |
@mltony: Sadly I forgot to mention two more things regarding to date:
|
|
Yep, of course this could be happen, but the date appears more often. In the end I suggest a checkbox for this, so the user can enable/disable sentence splitting here. By default splitting here should be disabled. |
Yep and Jaws uses the same keystroke to do the same thing.
…On 23/07/2018 01:15 p. m., Leonard de Ruijter wrote:
Wow, my apologies there. I really was quite sure that this was Word
functionality, but #3288
<#3288> turns out that this is
NVDA specific indeed.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#8518 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/API6eQ747lMs_ka7sqM2K_ayScTZODslks5uJiDJgaJpZM4VVy1H>.
|
This issue has been abandoned for some time now. Honestly, the more I think about this, the more I believe that Sentence Nav should stay as an add-on. |
I fundamentally disagree that one should have to get an addon to read by sentence. All other Windows-based screen readers I have used include this facility. As I mentioned previously, reading by sentence is (or should be) a basic reading mode. The discussion here became bogged down with debate about the best keystroke when the real issue is whether NVDA should provide people with the ability to read by sentence (incidentally, I changed to Windows-arrow keys). Can you give me one good reason why reading by sentence should not be provided, especially now that addons will cease to be available if their developers do not continue to revise them? Andrew |
@LeonarddeR |
This feature is so often requested by users, honnestly I don't know why it is so complicated to implement it. There is already an addon which works. Why not taking its core function and implement it into the core? Obviously this feature is not an exception, it is a navigation mode that every screen reader user would expect to belong to the standard package. |
Hi, part of it has to do with controls exposing such a feature (NVDA already supports sentence navigation in Microsoft Word because Word does expose this information). Another problem has to do with figuring out sentence demarcation in languages such as Chinese and others. Thanks.
|
This comment was marked as resolved.
This comment was marked as resolved.
A gem of a quote from #8518 (comment): "... primarily since only 10% of NVDA users know what is an add-on and how to install one, and that's probably an overly optimistic statement." Not sure of the accuracy of the statistic - my intuition is that it is - but I resonate with the sentiment. I was teaching NVDA to a beginner recently, and I realized how many add-ons I had to have him install in order to perform natural screen reading tasks he asked about. Anyhow, pinging @seanbudd in case there have been any updates since #8518 (comment). No worries if this fell through the cracks (happens to the best of us!), but please consider prioritizing sharing NV Access's position at the earliest given the age of this ticket and the level of interest. |
Due to other commitments, it took Tony some time to update SentenceNav to be compliant with NVDA 2023.1 and how frustrating it was for me. I intended to nag ... no, remind about this glaring omission in NVDA but did not get around to it. The above comment has coaxed me into action. Andrew |
We merged #13797. We've also added a Document Navigation category to the Settings panel. Sentence navigation is similar. What is NV Access's current stance on this feature request? Any updates? |
@seanbudd, @gerald-hartig, given #16031 implements an algorithm to detect sentence separators, it would really be the opportunity to state on this issue and to triage it. Also, the more because @mltony (author of sentence nav add-on) is available these days (on contrary to usual) and is quite productive; it would be a pity to miss this opportunity. NV Access has planned to look at this issue two years ago (see #8518 (comment)), but it seems that nothing has happened since then. |
We will take this feature. We already have moving by sentence in MS Word, using alt+up/downArrow. I have not looked at the add-on itself, but all I would ask is that it was abstract enough so that a particular TextInfo implementation can provide its own sentence unit if the underlying accessibility / platform API has a concept of sentences. Then in the cases where there is no native support, we will use the generalised algorithm. |
Thanks @michaelDCurran for the "triaged" label.
@mltony are you still interested in implementing this in core with the design suggested by @michaelDCurran, i.e. a general algorithm in
Jaws also uses Anyway, I am not concerned about this. |
@michaelDCurran: I changed these hotkeys from ALT+ArrowUP/ArrowDown to NVDA+ALT+ArrowUP/ArrowDown. |
Thanks @michaelDCurran , I will start working on that. |
I am unsure that the paragraph reconstruction of Sentence Nav add-on should be ported as is in NVDA core. |
@DrSooom |
For me, this works really well, and my use of sentence-nav relies heavily on this feature. |
@CyrilleB79 , I created a separaet issue #16089 to discuss whether it is feasible to fix paragraphing. TLDR, I don't see a good solution and I explain there why existing algorithm of SentenceNav won't work well for fixing paragraphing. But LMK if you have any other good ideas. |
@CyrilleB79, I didn't hear back from you regarding fixing paragraph definition #16089 - I assume you don't have any good ideas there, so since I don't see a good way to fix paragraph definition myself either, I'll plan to preserve SentenceNav logic and only reconstruct sentences across paragraphs. |
I have no better idea to detect paragraph accurately, and there will probably a need to do some tests. Anyway, I think that the algorithm to reconstruct paragraphs for sentence nav feature should be available in the "Paragraph style" parameter of the "Document navigation" settings category. We may then decide if sentence nav feature should follow this parameter to decide of paragraph reconstruction or if the type of paragraph should specifically be forced to the better algorithm for this feature. |
@seanbudd, @michaelDCurran
I know this appears to be ugly and hacky, but so far I couldn't come up with any better solution. Does anyone have a better idea? |
Also cc: @LeonarddeR - since you authored wide string converter - do you have any ideas regarding my question in previous comment? |
In Word, the caret cannot be placed before the bullet. In a line containing a bullet, the first position is after the bullet and the indentation, before the first text character. Thus the cursor actually moves over one character as expected. |
I know. But the problem is the first character in bullet list item stands for 3 characters. E.g., Put your cursor in the beginning of said list item and do:
So moving by 1 in terms of textInfo characters corresponds to moving by 3 in term of Pythonic string indices. My question is this: is there a way to somehow obtain this mapping for UIA text infos? My guess is not, that's why I am planning to do some version of binary search, but would be happy to learn if there is a better way. |
This function is needed for both #8518 and #16050. Summary of the issue: Suppose we have TextInfo that represents a paragraph of text: ``` > s = paragraphInfo.text > s 'Hello, world!\r' ``` Suppose that we would like to put the cursor at the first letter of the word 'world'. That means jumping to index 7: ``` > s[7:] 'world!\r' ``` The problem is that calling paragraphInfo.move(UNIT_CHARACTER, 7, "start") is not guaranteed to achieve desired effect. There are two main reasons for that: 1. In Wide character encoding, some 4-byte unicode characters are represented as two surrogate characters, whereas in pythonic string they would be represented by a single character. 2. In non-offset TextInfos (e.g. UIATextInfo) there is no guarantee on the fact that TextInfos.move(UNIT_CHARACTER, 1)would actually move by exactly 1 character. A good illustration of this is in Microsoft Word with UIA enabled always, the first character of a bullet list item would be represented by three pythonic characters: ◦ Bullet character "•" ◦ Tab character \t ◦ And the first character of of list item per se. 3. The third problem of TextInfo.move(UNIT_CHARACTER) function is its performance in some implementations. In particular, moving by 10000 characters in Notepad++ takes over a second on a reasonably modern PC. I might not need to move by 10000 characters in my upcoming PRs, but I will need to move by a few thousands for sure since for sentence navigation I would need to move within a paragraph and some large paragraphs in typical texts can easily be few thousands characters. I need to find both beginning and end textInfos, and if each operation takes say 200ms, then we'd be wasting almost half a second on just moving by characters. Since there were previous concerns about sentence navigation being not fast enough, II would like to introduce this efficient implementation. Here is how this can be done efficiently using this PR: ``` > info = paragraphInfo.moveToPythonicOffset(7) > info.setEndPoint(paragraphInfo, "endToEnd") > info.text 'world!\r' ``` Description of development approach 1. For general case, I implemented binary-search-like algorithm. I explained it in great detail in the code. Please see def moveToPythonicOffset function in textInfos\__init__.py. 2. I provided optimized implementations for OffsetsTextInfo and CompoundTextInfo. 3. I refactored textUtils.py making it conformant to OOP style. I implemented UTF8OffsetConverter and dummy IdentityOffsetConverter as well as their abstract base class and a function getOffsetConverter that selects correct converter based on encoding. I renamed a couple of methods of WideStringOffsetConverter in order to remove the word wide - as now I would like to use similar methods for UTF8 converter, and it has nothing to do with wide strings.
Tony Malykh's Sentence Nav add-on is a most valuable resource. Not only does it resolve #5805, but it allows reading by sentence in a wide variety of applications. I humbly suggest that the facility to read by sentence should be an integral component of a screen reader. I have checked with Tony and he is happy for me to make this suggestion.
Andrew
The text was updated successfully, but these errors were encountered: