Think of something that you wish Authorware could do but it doesn't?  Let the our good friends at Macromedia know via the wishlist.

Please let us know if you find any of the materials on this site inappropriate or offensive. Please include the url and why the material should be reviewed.

Comments and questions about the site are also welcome. Please no Authorware questions, use the AWARE list.

Back

1096 - Accessibility Kit: How do I tell when a piece of text has stopped being spoken?

by - Joe Ganci


I'm currently working quite extensively with some of the Accessibility Kit features, but I've not been able to solve one issue (for the moment - I'm sure there'll be others).

How do I tell when a piece of text has stopped being spoken? Apart from listening to it of course. I currently just have a long pause, which I don't like doing as most visually impaired users have the speed on the voice turned up to different but very high levels.


Use the VoiceState function. Here's the description:

voiceState() -- Gives the symbol indicating the current status. States are: #stopped, #playing, #paused.

So

if VoiceState() = #playing

You can loop. You can also keep looping UNTIL

VoiceState() = #stopped

Here's an example. You'll need to use a combination of SyncPoint/SyncWait in a repeat loop to foce the function to execute over and over:

repeat while voiceState() = #playing
SyncPoint(0)
SyncWait(0.1)
end repeat

When the repeat loop is exited, the voice has stopped.

There are 0 reviews
Add your review
Back