Make Punctuation/symbols dialog use voice language if appropriate #4930

Closed
nvaccessAuto opened this Issue Feb 18, 2015 · 12 comments

1 participant

@nvaccessAuto

Reported by jteh on 2015-02-18 03:55
(Spun off ticket:4210#comment:18.)
If "Trust voice's language when processing characters and symbols" is enabled, the voice language should be used for the symbol Pronunciation dialog, not NVDA's interface language. This should be relatively trivial: simply use speech.getCurrentLanguage instead of languageHandler.getLanguage. However, we need to test for any unexpected problems.

@nvaccessAuto

Comment 1 by leonarddr on 2015-02-18 08:25
As an addition, may be the language for which the symbols are being edited could be shown in the title bar?

@nvaccessAuto

Comment 2 by leonarddr on 2015-02-18 08:49
https://bitbucket.org/leonardder/nvda.git branch t4930 now uses speech.getCurrentLanguage for the Symbol dialog.

@nvaccessAuto

Comment 3 by leonarddr on 2015-02-18 09:28
It should be noted that languageHandler.getLanguage and speech.getCurrentLanguage differ at times. For example, the NVDA language could be nl and the voice language could be nl_NL. As far as i tested this, this isn't any problem for loading and saving to the right dictionary, CharacterProcessing deals with this. However, it makes displaying the edited language in the title bar a bit more tricky, as we can't just use languageHandler.getLanguageDescription.

@nvaccessAuto

Comment 4 by jteh on 2015-02-18 10:38
You should be able to use the locale attribute on the SpeechSymbolProcessor.

@nvaccessAuto

Comment 5 by leonarddr (in reply to comment 4) on 2015-02-18 14:53
Replying to jteh:

You should be able to use the locale attribute on the SpeechSymbolProcessor.

Ah, got that one.
Now also changed the title of the Symbol pronunciation dialog to include the language of the symbols currently being edited.

  • This includes moving the initialisation of the SymbolProcessor to a new initialisation method on SpeechSymbolsDialog
  • Also, the translatable string for the title is changed to allow inclusion of the language name
@nvaccessAuto

Comment 6 by jteh on 2015-02-19 01:06
Thanks!

@nvaccessAuto

Comment 7 by Leonard de Ruijter <alderuijter@... on 2015-02-20 04:07
In [8656374]:
```CommitTicketReference repository="" revision="8656374fb1c9f5098e4e0461797565e655eec015"
The Punctuation/symbols dialog now uses the voice language for viewing en editing symbols, re #4930

@nvaccessAuto

Comment 8 by Leonard de Ruijter <alderuijter@... on 2015-02-20 04:07
In [5b17b96]:
```CommitTicketReference repository="" revision="5b17b966b6532f71b619eee572cbe3bb59b4baf5"
Changed the title of the Symbol pronunciation dialog to include the language of the symbols currently being edited.

  • This includes moving the initialisation of the SymbolProcessor to a new initialisation method on SpeechSymbolsDialog
  • Also, the translatable string for the title is changed to allow inclusion of the language name

Re #4930

@nvaccessAuto

Comment 9 by James Teh <jamie@... on 2015-02-20 04:07
In [a3260c1]:
```CommitTicketReference repository="" revision="a3260c12511a55f0ccabf5aa7e184e76fb01d6e5"
Merge branch 't4930' into next

Incubates #4930.

Changes:
Added labels: incubating
@nvaccessAuto

Comment 10 by jteh on 2015-02-20 04:09
Nice work! I tweaked the translator comment to describe what %s is.

@nvaccessAuto

Comment 11 by leonarddr on 2015-02-20 11:43
Great, thanks for incorporating this.
I'd like to suggest the following user guide change:

This dialog allows you to change the way punctuation and other symbols are pronounced, as well as the symbol level at which they are spoken.

  • The language for which symbol pronunciation is being edited will be shown in the dialog's title. Note that this dialog respects the "Automatic Language switching" and "Trust voice's language for processing symbols and characters" options found in the Settings dialog #VoiceSettings; i.e. it uses the voice language rather than the NVDA global language setting when one or both these options are enabled. When both these options are disabled, nvda will use the global language setting for pronouncing and editing symbols.
@nvaccessAuto

Comment 12 by James Teh <jamie@... on 2015-04-08 05:16
In [3dd459f]:
```CommitTicketReference repository="" revision="3dd459f9aae3f3e367976d095bf3a1e051713cbb"
If the "Trust voice's language when processing characters and symbols" option is enabled, the Punctuation/Symbol pronunciation dialog now correctly uses the voice language. Also, the language for which pronunciation is being edited is shown in the dialog's title.

Fixes #4930.

Changes:
Removed labels: incubating
State: closed
@nvaccessAuto nvaccessAuto added this to the 2015.2 milestone Nov 10, 2015
@michaelDCurran michaelDCurran pushed a commit that referenced this issue Nov 23, 2015
Leonard de Ruijter The Punctuation/symbols dialog now uses the voice language for viewin…
…g en editing symbols, re #4930
8656374
@michaelDCurran michaelDCurran pushed a commit that referenced this issue Nov 23, 2015
Leonard de Ruijter Changed the title of the Symbol pronunciation dialog to include the l…
…anguage of the symbols currently being edited.

* This includes moving the initialisation of the SymbolProcessor to a new initialisation method on SpeechSymbolsDialog
* Also, the translatable string for the title is changed to allow inclusion of the language name

Re #4930
5b17b96
@jcsteh jcsteh added a commit that referenced this issue Nov 23, 2015
@jcsteh jcsteh If the "Trust voice's language when processing characters and symbols…
…" option is enabled, the Punctuation/Symbol pronunciation dialog now correctly uses the voice language. Also, the language for which pronunciation is being edited is shown in the dialog's title.

Fixes #4930.
3dd459f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment