Repository: nvaccess/nvda

Issue:
when trying to read emoticons with any synthesizer with cldr data processing enabled, these were not read
<!--
Please thoroughly read NVDA's wiki article on how to fill in this template, including how to provide the required files.
Issues may be closed if the required information is not present.
https://github.com/nvaccess/nvda/wiki/Github-issue-template-explanation-and-examples
-->

### Steps to reproduce:
1. Type the text with emoticons
2. try to read it with any synthesizer, language or voice of the synthesizer,
note, this bug also affects espeak,
3. try to read emoticon symbols with arrow keys, and using the review cursor commands.
note that emoticons symbols are not readable by word and when reading whole text
### Actual behavior:
emoticons are not read with cld data enabled
### Expected behavior:
emoticons should be read
### System configuration:
windows 10 1809 17763
#### NVDA Installed/portable/running from source:
installed
#### NVDA version:
latest alpha, alpha-16149,e713f614
#### Windows version:
10.0.17763 /1809
#### Name and version of other software in use when reproducing the issue:
n/a not applicable
#### Other information about your system:

### Other questions:

#### Does the issue still occur after restarting your PC?
yes
#### Have you tried any other versions of NVDA?
no, and not applicable, as this is the new feature recently included



Discussion:
Note that the CLDR data *does not* contain emoticon descriptions, only emoji descriptions.

* Emoticons include `:D`, `:)`, and `;)`
* Emoji include 👍🏻, 😂, and ❤
Hi,

When i say emoticons, i mean emojies, 

 

From: Leonard de Ruijter <notifications@github.com> 
Sent: Tuesday, October 9, 2018 1:35 PM
To: nvaccess/nvda <nvda@noreply.github.com>
Cc: zstanecic <zvonimirek222@yandex.com>; Author <author@noreply.github.com>
Subject: Re: [nvaccess/nvda] when trying to read emoticons with any synthesizer with cldr data processing enabled, these were not read (#8826)

 

Note that the CLDR data does not contain emoticon descriptions, only emoji descriptions.

*	Emoticons include :D, :), and ;)
*	Emoji include 👍🏻, 😂, and ❤

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub <https://github.com/nvaccess/nvda/issues/8826#issuecomment-428158518> , or mute the thread <https://github.com/notifications/unsubscribe-auth/AKohk0YM5u-4uFf-afTxn_04cL5g8Rqmks5ujInMgaJpZM4XMB3E> .  <https://github.com/notifications/beacon/AKohk6lxj8tFGH8eSOZk7DQD7MAgC1T3ks5ujInMgaJpZM4XMB3E.gif> 


A quick talk with @zstanecic revealed that he was using speech at the none symbol level, and in this case, emojis won't be read.
We might want to document this.
Given the request we have received, I think it makes sense to do the following:

1. Speak emoji at the none level as well, which basically means that they're always spoken
2. Add a script/gesture to disable/enable emoji processing. I propose shift+NVDA+p.

Resolving patch:
diff --git a/source/globalCommands.py b/source/globalCommands.py
--- a/source/globalCommands.py
+++ b/source/globalCommands.py
@@ -2282,6 +2282,23 @@ def script_recognizeWithUwpOcr(self, gesture):
 	# Translators: Describes a command.
 	script_recognizeWithUwpOcr.__doc__ = _("Recognizes the content of the current navigator object with Windows 10 OCR")
 
+	@script(
+		# Translators: Input help mode message for toggle report CLDR command.
+		description=_("Toggles on and off the reporting of CLDR characters, such as emojis"),
+		category=SCRCAT_SPEECH,
+	)
+	def script_toggleReportCLDR(self, gesture):
+		if config.conf["speech"]["includeCLDR"]:
+			# Translators: presented when the report CLDR is toggled.
+			state = _("report CLDR characters off")
+			config.conf["speech"]["includeCLDR"] = False
+		else:
+			# Translators: presented when the report CLDR is toggled.
+			state = _("report CLDR characters on")
+			config.conf["speech"]["includeCLDR"] = True
+		characterProcessing.clearSpeechSymbols()
+		ui.message(state)
+
 	@script(
 		# Translators: Describes a command.
 		description=_(


Test patch: