WebAIM - Web Accessibility In Mind

E-mail List Archives

Re: Highlighting static HTML using the keyboard

for

From: Andre Polykanine
Date: Oct 15, 2018 2:04PM


Hi Isabel,

> I'd really appreciate any thoughts you can come up with.

Sorry, but just from the top of my head:
They select a part of text with their keyboard as usual, then press,
say, Ctrl+P. You bind an onclick event of a button to that keystroke.
When the button is clicked, you pass the selected text to the
Synthesis API and play it through:
https://developer.mozilla.org/en-US/docs/Web/API/Web_Speech_API
See the section about speech synthesis. However, the browser should be
relatively new and should not be IE.
Sorry, if I didn't understand your request correctly.

--
With best regards from Ukraine,
Andre
Skype: menelion_elensule
Twitter (English only): @AndrePolykanine


------------ Original message ------------
From: Isabel Holdsworth < <EMAIL REMOVED> >
To: WebAIM Discussion List
Date created: , 4:55:15 PM
Subject: [WebAIM] Highlighting static HTML using the keyboard


Hi all,

A customer wants us to add speech synthesis to their website. They
want to be able to highlight a block of text on the page that could be
anything from a single character to a whole paragraph, and have it
read aloud.

I can't think how to implement this functionality using a keyboard,
apart from making the whole page into a contenteditable div, which
would be a big no-no.

Is there any dyslexia software that offers this type of keyboard
navigation? If so that would give me a starting point at least.

I'd really appreciate any thoughts you can come up with.

Cheers, Isabel