The HTMLElement node class
The Text node class
The Document class
The adaptor to work with typeset nodes.
The adaptor to use for DOM access.
The worker options.
The adaptor to use for DOM access.
The list of valid commands from the Worker.
Callback for ready signal
Protected
workerThe webworker
Attach the speech structure to an item's DOM
The SpeechMathItem to attach to
True when speech should be added
True when Braille should be added
The speech JSON structure to attach
Remove a task from the task list.
The item whose task is to be canceled.
Worker call to compute clearspeak preferences for the current locale.
The options list.
Map to store the compute preferences.
The promise that resolves when the command is complete
Computes the clearspeak preference category that are semantically relevant for the currently focused node.
The linearized mml expression.
The semantic id of node to compute the preference for.
Map for recording the computed preference.
Counter for storing the result in the map.
The promise that resolves when the command is complete
Remove speech attributes from a MathItem
The MathItem whose speech attributes should be removed.
Recursively remove speech attributes from a DOM tree
The root node of the tree to modify
Listener for the messages from the worker. The message will contain a command and data, and we look in the list of commands to see if we have an implementation for the given one. If so, we run the command on the data from the message, otherwise we throw an error.
The message event.
Computes the next rule set for this particular SRE setting. We assume that the engine has been set to the options of the current expression.
The mml string.
The options list.
The mathitem for reattaching the speech.
A promise that resolves when the command completes
Computes the next style for the particular SRE settings and the currently focused node. We pass the options of the current expression.
Note, that we compute not only the next style but also the next speech structure in the method, as smart computation is done wrt. the semantic node, and we do not want to reconstruct the semantic XML tree on the SRE side twice. Hence we pass the math expression, plus the semantic ID of the currently focused node.
The linearized mml expression.
The options list.
The semantic Id of the currenctly focused node.
The mathitem for reattaching the speech.
A promise that resolves when the command completes
Send messages to the worker.
The command message.
Optional
item: SpeechMathItem<N, T, D>Optional SpeechMathItem that is being processed command name as input.
A promise that resolves when the command completes
Protected
setAdds a set of attributes to the given node.
The node on which to set attributes.
The attribute to value map.
A possible prefix for the attribute name.
Optional
keys: string[]An optional list to select only those attributes.
Protected
setAdd the speech attributes to a node
The node to add speech to
The speech data to use
True when speech should be added
True when Braille should be added
Protected
setSetup the engine in the SRE worker.
The options list.
A promise that resolves when the command completes
Compute speech structure for the math.
The mml string.
The options list.
The mathitem for reattaching the speech.
A promise that resolves when the command completes
This starts the worker.
Stop the worker and clear the values so that the worker can be restarted, if desired.
Terminates the worker.
The main WorkerHandler class