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

Announcement of keyboard layout changes depending on context should be optional. #1676

Open
nvaccessAuto opened this issue Jul 16, 2011 · 38 comments
Labels
component/speech enhancement p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority

Comments

@nvaccessAuto
Copy link

Reported by MHameed on 2011-07-16 19:18
For multi lingual users, at the moment when they are in edit areas such as in wordpad or word and they move between lines written in different languages, NVDA automatically announces the change made to the keyboard layout depending on the current line.

I.e. if it is a line in english, then any inserted will be using the english layout.
english.

The issue is that when the user is reading a multi-lingual document, they keep hearing layout arabic Egypt, english US, etc.

The announcement is useful for editing, but irritating for reading, so we need an option to suppress it.

Thanks.

@nvaccessAuto
Copy link
Author

Comment 1 by fatma.mehanna on 2011-10-29 12:51
hi devs,
can you try to fix this issue in the incoming release?
it is irritating us as we read multi lingual documents.
we don't have to hear the keyboard layouts when we read each line. this wastes much time.
thanks.

@nvaccessAuto
Copy link
Author

Comment 2 by jteh on 2011-10-30 00:07
This can't be added for 2011.3, as it's now frozen.

If we add this, they will never be announced if disabled; i.e. even when you press keys to manually switch layouts. Is this what you want?

@nvaccessAuto
Copy link
Author

Comment 4 by jteh on 2012-10-09 06:41
comment:2 is still an open question.

@nvaccessAuto
Copy link
Author

Comment 5 by MHameed (in reply to comment 2) on 2012-10-09 07:14
Replying to jteh:

If we add this, they will never be announced if disabled; i.e. even when you press keys to manually switch layouts. Is this what you want?

Not ideal, but if it cant be done any other way then this will be better than the current situation.

Idealy we would only want the announcements to be done when invoked using any of the switching layout/IME keys, and not announced otherwise.

@fatima, I think Mick recently changed some of the programming logic in that area of the code, can you please try to reproduce the issue and provide a log file, (input/output).

steps:

Please make a file (and attach) containing few lines of arabic, a few lines in english, a few lines in arabic. try to have 5 or more alternating blocks of arabic and english.

log 1:
from line 1, do a sayall, until the end of the document.
and attach log.

log 2:
from line 1, use down arrow, downarrow until we reach the end of the document.
Also attach this second log.
Thanks.

@nvaccessAuto
Copy link
Author

Attachment line by line.log added by fatma.mehanna on 2012-10-09 20:17
Description:

@nvaccessAuto
Copy link
Author

Attachment sayAll.log added by fatma.mehanna on 2012-10-09 20:18
Description:

@nvaccessAuto
Copy link
Author

Comment 6 by fatma.mehanna on 2012-10-09 20:26
hi,
i used the latest snapshot, 5526, and the problem still exists.
unfortunately, it became worse.
before, we were hearing only one keyboard layout during reading, i.e, "arabic" or "english us".
now, we hear the 2 keyboard layouts during reading the same line.
moreover, we also started to hear additional information, such as "arabic -arabic egypt 101"
i attached 2 log files following mesar instructions:
1 for reading line by line.
2 for reading with sayAll command.
i reproduced it using wordpad.
thanks for your efforts.

@nvaccessAuto
Copy link
Author

Comment 7 by jteh (in reply to comment 5) on 2012-10-10 01:54
Replying to MHameed:

If we add this, they will never be announced if disabled; i.e. even when you press keys to manually switch layouts.

Idealy we would only want the announcements to be done when invoked using any of the switching layout/IME keys, and not announced otherwise.

That's pretty ugly. It'd mean we'd need to know and bind all possible switching methods, remembering that some layouts introduce their own. Also, what if the system switches for some other reason? What if the user switches to a different application where the input language/layout was set to something else? What if the user assumed the layout/language had changed but it really hadn't and started typing in the wrong language? The correct behaviour really is to respond to these changes automatically. So, the best we can do is provide an option to disable them altogether. This way, the user very clearly understands what they're getting.

@nvaccessAuto
Copy link
Author

Comment 8 by jteh on 2012-10-10 08:14
Changes:
Milestone changed from None to 2012.3

@nvaccessAuto
Copy link
Author

Comment 9 by mdcurran on 2012-10-11 16:00
Firstly its worth noting that when moving with the arrow keys, the layout change is announced after the text. This means it does not interrupt the text, but its also good as it clearly alerts you to the fact that the input locale has really changed based on where the caret is.
I do agree though that having these layout changes announced during sayAll is inappropriate and also confusing.

Therefore, I would like to propose that we do not announce layout changes while a sayAll is running. (we don't have a way of doing this yet, but I don't think it would be that tricky).

I don't believe we should have a global setting for disabling all layout change announcements as (if I'm correct) users who type in both Arabic and English would be constantly switching, and therefore would like announcements when this happens. I would think that both switching layouts when typing, and reading documents with both Arabic and English with sayAll/arrows would be pretty much the same user scenario. However, if someone can suggest that there would be a group of people happy to receive no announcements both either for manual layout changes or layout changes due to caret navigation, then we can add the setting.

@nvaccessAuto
Copy link
Author

Comment 10 by mdcurran on 2012-10-12 02:08
Changeset:main,5538 no longer announces keyboard layout changes while a sayAll is in progress. No matter what is decided about the other setting, I think this is still needed anyway.

@nvaccessAuto
Copy link
Author

Comment 11 by MHameed (in reply to comment 9) on 2012-10-12 09:49
Replying to mdcurran:

I don't believe we should have a global setting for disabling all layout change announcements as (if I'm correct) users who type in both Arabic and English would be constantly switching, and therefore would like announcements when this happens.

this is true, but we have to consider this option only as the last resort.

The feedback is that when they are in edit fields and move between english/arabic, they expect the layout to change, and therefore nvda is being too verbose/distracting.

I havent looked at the code, but maybe something like:

I assume the layout is an event and we are just listening for it.

if cursorPosBeforeEvent == cursorPosAfterEvent:
# looks like keyboard triggered, so speak it.
ui.message("layout %s" %newLayout)

dont know how much of a hack this is.

Thanks for the sayall fix.

@nvaccessAuto
Copy link
Author

Comment 12 by fatma.mehanna on 2012-10-19 19:36
hi,
thanks very much for fixing this issue with the say all command.
we really appreciate that, but as mesar said, the user knows that he/she is typing arabic or english. there are some ways for him/her to know that, among these is enabling the speaking of typed characters or by pressing the key board layout changing shortcut.
if you don't want to implement the option, so disable this feature and as i mentioned above there are ways by which the user can know which keyboard layout he/she uses.
thanks.

@nvaccessAuto
Copy link
Author

Comment 13 by jteh on 2012-10-21 22:23
I'm pretty sure we'd receive the layout change event asynchronously from the cursor position movement, so we can't use the cursor position info to determine whether we speak it.

I still don't follow the problem here. The layout is spoken after the text, so it's not actually an obstruction to efficiency. It's also more reliable than guessing whether the layout changed, which may not always happen as expected; e.g. if there are more than just these two layouts installed.

@nvaccessAuto
Copy link
Author

Comment 14 by jteh on 2012-10-22 21:39
If an option to disable all layout reporting is what you want (which I still think is a very bad idea, particularly if you have more than two layouts), this will have to be deferred to 2013.1.
Changes:
Milestone changed from 2012.3 to 2013.1

@nvaccessAuto
Copy link
Author

Comment 15 by mdcurran on 2013-01-30 04:03
Marking as wontfix for now re comment 13. Feel free to debate this further though.
Changes:
Added labels: wontfix
State: closed

@nvaccessAuto
Copy link
Author

Comment 16 by MHameed (in reply to comment 13) on 2013-02-19 16:06
Replying to jteh:

I'm pretty sure we'd receive the layout change event asynchronously from the cursor position movement, so we can't use the cursor position info to determine whether we speak it.

Can you please check if its indeed being received asynchronously?

I still don't follow the problem here. The layout is spoken after the text, so it's not actually an obstruction to efficiency.

It is an obstruction to flow, for example when proof reading a document.

Sorry for reopening, users absolutely insistant that we should try to find a reasonable solution for this, I'm just the messenger.

@nvaccessAuto
Copy link
Author

Comment 17 by MHameed on 2013-02-19 16:07
Changes:
Removed labels: wontfix
State: reopened

@nvaccessAuto
Copy link
Author

Comment 18 by ruslan on 2013-02-19 17:04
Hi!
It is very uncomfortable when nvda anounces keyboard layout while reading multilingual text.
This problem occurs in wordpad while reading arabic russian and english text at the same time.
Thanks for support and understanding.
ruslan

@nvaccessAuto
Copy link
Author

Comment 19 by mdcurran on 2013-02-20 00:44
Seriously, all we can do is add an option to not announce changes whether they are automatic or through keyboard input. There is no way to detect the difference as there are just too many different ways to change the layout.
If this is suitable I will add the option.

@nvaccessAuto
Copy link
Author

Comment 20 by ruslan on 2013-02-20 03:06
Hi mdcurran!
It would be suitable really, if you will add the option that allows switching anoncement of keyboard layout.
Thank you very much!

@nvaccessAuto
Copy link
Author

Comment 21 by fatma.mehanna on 2013-02-20 15:16
if this is the only solution for solving this issue, then the option should be added till NVDA can be customizable, so we can configure it according to each application.

@nvaccessAuto
Copy link
Author

Comment 22 by fatma.mehanna on 2013-02-21 22:25
hi,
I noticed during my descussion with the other multi lingual users about this ticket that they don't face this problem. We found out that the reporting of keyboard layout change happens because arabic is an rtl language, and most of the multi lingual users use only left to right languages, so nvda reports the layout change because it sees 2different writing directions.
i reported this piece of information in case it can be of help.

@nvaccessAuto
Copy link
Author

Comment 23 by jteh on 2013-02-22 04:04
As far as I know, it's not just that we don't report the layout change. It actually doesn't change automatically when navigating through text written in other languages. This seems to be unique to RTL layouts. NVDA isn't doing anything different here.

At any rate, it's too late to get this fixed for 2013.1.
Changes:
Milestone changed from 2013.1 to 2013.2

@nvaccessAuto
Copy link
Author

Comment 24 by jteh on 2013-06-26 02:57
Changes:
Milestone changed from 2013.2 to near-term

@nvaccessAuto
Copy link
Author

Comment 25 by fatma.mehanna on 2015-04-13 09:56
hi,
any news about this ticket?
the problem still exists since 2011.
i think so as long nvda became customizable, this can be solved by any way.
for those who can't follow the problem, he/she should add the arabic keyboard layout and type in an application such as word/wordpad/skype.
thanks.

@nvaccessAuto nvaccessAuto added this to the near-term milestone Nov 10, 2015
@jcsteh jcsteh removed this from the near-term milestone Jun 24, 2016
@nvaccessAuto nvaccessAuto added the p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority label Jul 5, 2016
@dkager
Copy link
Collaborator

dkager commented Jul 2, 2017

To clarify, would this also affect the notorious message "English (United States) - United States-International"?

@bhavyashah
Copy link

This ticket has witnessed extensive discussion and many comments. Unfortunately, I am not too sure I understand the feature request properly though. I hear the language whose keyboard layout I have switched to when pressing Alt+Shift, and that announcement is perfectly useful the way it is. Therefore, I am at a loss as to what behaviour change is being proposed as part of this lengthy ticket. Clarifications to my doubts and @dkager's #1676 (comment) would be truly appreciated.

@dkager
Copy link
Collaborator

dkager commented Sep 6, 2017

When you switch between applications on a system with English (US) locale, you will often get messages like "English (United States) - United States-International". In this case a toggle to disable such announcements from NVDA would be quite useful. In real multi-lingual situations, this toglle would of course not be so useful.

@LeonarddeR
Copy link
Collaborator

LeonarddeR commented Jan 22, 2018

@dkager commented on 6 Sep 2017, 11:57 CEST:

When you switch between applications on a system with English (US) locale, you will often get messages like "English (United States) - United States-International". In this case a toggle to disable such announcements from NVDA would be quite useful. In real multi-lingual situations, this toglle would of course not be so useful.

@dkager, are you sure you have just this keyboard setting installed (i.e. you can't switch with alt+shift)?

In that case, would it be possible to see what language/layout combinations are available, and if only one, ignore the language switches as they make no sense at all in such a situation?

@dkager
Copy link
Collaborator

dkager commented Jan 22, 2018

@dkager, are you sure you have just this keyboard setting installed (i.e. you can't switch with either control+alt or alt+shift)?

Yes. The same happens if you only have Dutch as a language/layout.

@dkager
Copy link
Collaborator

dkager commented Jan 22, 2018

The two messages I'm getting are:

  1. English (United States) - United States-International
  2. United States-International

So it seems that sometimes the language is missing.

@dkager
Copy link
Collaborator

dkager commented May 27, 2018

I want to spend an evening looking at the particular problem I mentioned above, namely that an empty language name but same input method name still causes a message. A further problem I want to look at is the very first input switching message you get after starting NVDA. This appears to come from the fact that the lastInputMethodName variable is empty by default.

@LeonarddeR Do you have any additional thoughts before I start looking at this?

@dkager
Copy link
Collaborator

dkager commented Jun 15, 2018

Alright, so there are two separate requests:

  1. An option to completely disable reporting keyboard layout switches. That is the topic of tis issue. See Announcement of keyboard layout changes depending on context should be optional. #1676 (comment)
  2. Suppress the redundant reporting of keyboard layout switches from/to the same language and input method. See nvda announces keyboard and input language in weird places #7383.

The only question to conclusively answer in this issue is if we want an option to completely disable reporting keyboard layout switches.

@LeonarddeR
Copy link
Collaborator

If layout switches are announced when reading text, I think these announcements should be suppressed when in say all, which should be very easy to accomplish.

@dkager
Copy link
Collaborator

dkager commented Jun 15, 2018

If layout switches are announced when reading text, I think these announcements should be suppressed when in say all, which should be very easy to accomplish.

That is already implemented. The problem described in this issue only occurs when reading line by line, or by character, etc.

@LeonarddeR
Copy link
Collaborator

Hmm in that case, I guess we could be open for any pr that allows disabling announcements altogether.

@Adriani90
Copy link
Collaborator

As far as I understand this issue, the keyboard layout changes automatically while reading line by line, character by character etc. The problem is that NVDA announces every change while reading. In my opinion, if an user wants just to read the document, there should be a keystroke to disable and enable automatic keyboard layout change.
As far as I under stand, the issue is annoying when reading a significant part of a document, not only a line. So, turning off automatic layout change with a keystroke is a viable solution. After reading, the user can press the keystroke again and enable automatic layout change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/speech enhancement p3 https://github.com/nvaccess/nvda/blob/master/projectDocs/issues/triage.md#priority
Projects
None yet
Development

No branches or pull requests

6 participants