!7 p-exp { serveHttpIfMain(); } html { ret htitle("Speech Output Test") + p("Press F12 to open console") + "Text to say: " + htextinput("text", id := "thetext", onKeyUp := [[if (event.keyCode == 13) { say(document.getElementById("thetext").value); return false; }]]) + hWebKitSayFunction() + hjavascript([[ function checkStatus() { if (window.speechSynthesis.speaking) console.log("Speaking"); else console.log("Not speaking"); setTimeout(checkStatus, 200); } checkStatus(); ]]); }