Skip to content

Split speech processing commands and commands for synth #12778

@feerrenrut

Description

@feerrenrut

Is your feature request related to a problem? Please describe.

  • Speech commands for synthesizers and speech commands for internal speech processing are not well separated.
  • The SpeechManager class is the boundary between internal speech processing and the synthesizer, however it isn't entirely clear which commands may exist on either side of that boundary.
  • SynthDrivers have a list of supported commands, however these aren't actually considered anywhere.

Describe the solution you'd like

  • Make a new base class for SynthCommands. Commands like PitchCommand should inherit from there.
  • Either through design (better), or documentation (worse) make the separation of intents for commands for synth and internal speech commands clear .
  • Enforce SynthDriver.supportedCommands from speech manager (with reasonable defaults if the driver provides and empty list).

Reasonable defaults is probably:

	supportedCommands = {
		IndexCommand,
		CharacterModeCommand,
		LangChangeCommand,
		BreakCommand,
		PitchCommand,
		RateCommand,
		VolumeCommand,
		PhonemeCommand,
	}

Describe alternatives you've considered

None

Additional context

While working on #12710 the conflated purposes of speech commands became clear.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Addon/APIChanges to NVDA's API for addons to support addon development.component/speech

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions