<doc>
  <legacy_id>3512</legacy_id>
  <name>revSetSpeechProvider</name>
  <type>command</type>
  <syntax>
    <example>revSetSpeechProvider <i>speechProvider</i></example>
  </syntax>
  <library>Speech library</library>
  <objects>
  </objects>
  <synonyms>
  </synonyms>
  <classification>
  </classification>
  <references>
    <command tag="revSetSpeechSpeed">revSetSpeechSpeed Command</command>
    <command tag="revUnloadSpeech">revUnloadSpeech Command</command>
    <command tag="revSetSpeechVolume">revSetSpeechVolume Command</command>
    <function tag="revSpeechVoices">revSpeechVoices Function</function>
  </references>
  <history>
    <introduced version="2.8.1">Added.</introduced>
  </history>
  <platforms>
    <mac/>
    <windows/>
  </platforms>
  <classes>
    <desktop/>
    <server/>
    <web/>
  </classes>
  <security>
  </security>
  <summary>The <i>speechProvider</i> is either "sapi4", "sapi5" or "speechmanager", or empty for the default.</summary>
  <examples>
    <example>revSetSpeechProvider "speechmanager"</example>
    <example>revSetSpeechProvider "sapi5"</example>
  </examples>
  <description>
    <p>Sets the API that LiveCode uses to speak. SAPI4 and SAPI5 are only supported on Windows.  SpeechManager is only supported on OS X.  This command will not return anything in the result. If an invalid API is specified, the default API for the currrent platform will be used.</p><p/><p>The default is speechManager on OS X and SAPI5 on Windows (falling back to SAPI4 if SAPI5 is not supported).</p><p/><p>Changes to the speech provider will take affect straight away if the speech library was not loaded (i.e. nothing has been spoken), otherwise they will not take affect until the speech library is reloaded using the <command tag="revUnloadSpeech">revUnloadSpeech command</command> followed by the <command tag="revUnloadSpeech">revUnloadSpeech command</command>.  If the specified speech provider cannot be loaded then the <command tag="revUnloadSpeech">revUnloadSpeech command</command> will return "sperr, unable to load speech provider" in the <function tag="result">result</function>.</p>
  </description>
</doc>