Skip to main content
All docs
V25.1
  • NusaSettings Class

    Contains members that allow you to to bind the Rich Text Editor to the Nuance SpeechKit.

    Declaration

    export class NusaSettings
    See Also

    Properties

    registered Property

    Returns whether or not the RichEdit control is registered in the Nuance Dragon SpeechKit.

    Declaration

    get registered(): boolean

    Property Value

    Type Description
    boolean

    true if the RichEdit control is registered in Nuance Dragon SpeechKit; otherwise, false.

    Methods

    getCommandHandler Method

    Indicates whether the specified command has a handler.

    Declaration

    getCommandHandler(): (commandId: string, placeholderIds: string[], placeholderValues: string[]) => boolean

    Returns

    Type Description
    (commandId: string, placeholderIds: string[], placeholderValues: string[]) => boolean

    true if the command with the specified parameters has a handler; otherwise, false.

    getCustomContainer Method

    Returns an object that identifies the RichEdit container and allows you to get and set a RichEdit control focused in the Nuance SpeechKit.

    Declaration

    getCustomContainer(): NusaCustomContainerType | null

    Returns

    Type Description
    NusaCustomContainerType

    An object that identifies the RichEdit container. null if the RichEdit control’s container is not registered in Nuance SpeechKit.

    getCustomControl Method

    Returns an object that contains RichEdit Nuance-related settings.

    Declaration

    getCustomControl(): NusaCustomControlType | null

    Returns

    Type Description
    NusaCustomControlType

    An object that contains Nuance-related settings. null if the RichEdit control is not registered in Nuance SpeechKit.

    getFocusedRichEdit Method

    Returns the focused RichEdit control.

    Declaration

    getFocusedRichEdit(): RichEdit | null

    Returns

    Type Description
    RichEdit

    The RichEdit control. null if a focused RichEdit control is not found.

    register Method

    Registers the RichEdit control in the Nuance Dragon SpeechKit.

    Declaration

    register(
        options?: NusaRegisterOptions
    ): void

    Parameters

    Name Type Description
    options NusaRegisterOptions

    The options to be registered.

    Remarks

    Register a RichEdit control in the Dragon SpeechKit’s NUSA_configure method to enable Nuance API support in RichEdit. Note that you should register every RichEdit control on the page. After registration, a control can processes the Nuance standard built-in commands.

    function NUSA_configure() {
        // ...
        // register every RichEdit control that should work with Nuance functionality
        richEdit1.nusaSettings.register();
        richEdit2.nusaSettings.register();
    }
    

    registerCommands Method

    Registers RichEdit Nuance-related commands.

    Declaration

    registerCommands(options?: {
        customizeCommands?: (commandSets: NusaCommandSet[], placeholders: NusaPlaceholder[]) => void;
    }): void

    Parameters

    Name Type Description
    options {customizeCommands: (commandSets: NusaCommandSet[], placeholders: NusaPlaceholder[]) => void}

    A function that allows yo to modify command settings.

    Remarks

    Regardless of the number of RichEdit controls on the page, the registerCommands function should be called only once.

    unregister Method

    Unregisters the RichEdit control from Nuance Dragon SpeechKit.

    Declaration

    unregister(): void