plugin
The community/plugin
directory contains a collection of subdirectories, each implementing a distinct set of features to enhance the Talon voice control experience. These plugins range from basic text manipulation and command repetition to complex desktop management and custom UI elements.
Here's an overview of the most significant subdirectories and files:
macro
: This directory implements a macro recording and playback system. It containsmacro.talon
, which defines voice commands for recording, playing, saving, and copying macros, andmacro.py
, which contains the Python logic for managing the macro recording and playback process. These files work together to allow users to automate sequences of voice commands.desktops
: This directory provides cross-platform virtual desktop management. It includesdesktops.py
, which defines the basic actions,desktops.talon
, which exposes the actions via voice commands, and platform-specific implementations indesktops_mac.py
,desktops_linux.py
, anddesktops_win.py
. This allows users to switch between virtual desktops and move windows across them using voice.mouse
: This directory provides comprehensive mouse control through voice. It includesmouse_cursor.py
which controls the mouse cursor,mouse.talon
which provides the voice commands for mouse control,mouse.py
which defines mouse actions, andmouse_scroll.py
which implements mouse wheel scrolling and gaze-based scrolling.talon_draft_window
: This directory contains code for a dedicated text editing window, leveraging word labels for voice-driven manipulation. It includesdraft_talon_helpers.py
which initializes the module, contexts, and actions,draft_ui.py
which manages the text area and labels,draft_window_open.talon
anddraft_window.talon
which define voice commands, anddraft_global.talon
for global commands.repeater
: This directory adds functionality to repeat commands and phrases. It includespop_twice_to_repeat.py
which repeats a command on a double pop noise, andrepeater.talon
which defines voice commands for repeating actions, phrases, and commands a specified number of times.datetimeinsert
: This directory provides a plugin for inserting the current date and time in various formats. It includesdatetimeinsert.py
, which defines the actions for formatting time, anddatetimeinsert.talon
, which exposes the actions via voice commands.cancel
: This directory provides a way to cancel a spoken command using the phrase "cancel cancel". It includescancel.py
which handles the cancellation logic, andcancel.talon
which defines the "cancel cancel" command.subtitles
: This directory provides a plugin to display subtitles of speech input on the screen. It includeson_phrase.py
which captures spoken phrases,subtitles.py
which handles the display logic and settings, andsubtitles.talon
which defines the default settings.are_you_sure
: This directory implements a confirmation dialog before executing a potentially destructive action. It includesare_you_sure.py
which manages the confirmation dialog, andare_you_sure.talon
which defines the voice commands for confirming or canceling.talon_helpers
: This directory contains debugging and helper utilities for Talon. It containstalon_helpers.talon
for voice commands,talon_helpers.py
for python actions, andcreate_app_context.py
for actions related to creating new app contexts.gamepad
: This directory provides gamepad support for Talon. It includesgamepad.py
andgamepad.talon
which implement the core gamepad functionality, andgamepad_tester.py
and related.talon
files which implement an on-screen visual representation of the gamepad state.text_navigation
: This directory implements advanced text navigation using voice. It includestext_navigation.py
which contains the logic for moving, selecting, and deleting text, andtext_navigation.talon
,before_or_after.talon-list
andnavigation_action.talon-list
which define the voice commands and vocabulary.then
: This directory includesthen.talon
, which provides a "then" command to chain otherwise ambiguous commands.microphone_selection
: This directory contains files for a microphone selection UI. It includesmicrophone_selection.py
which creates the UI, andmicrophone_selection.talon
which provides the voice commands.draft_editor
: This directory contains files for using a text editor as a draft editor in Talon. It includesdraft_editor.py
which manages the draft editor, anddraft_editor.talon
anddraft_editor_open.talon
which define the voice commands for opening, submitting, and discarding the draft.symbols
: This directory provides commands for inserting and wrapping text with various symbols. It containssymbols_deprecated.talon
with deprecated commands, andsymbols.talon
for the new preferred method of inserting symbols.media
: This directory implements basic media controls. It includesmedia.py
, which defines a customplay_pause
action, andmedia.talon
, which exposes the action as a voice command.command_history
: This directory adds command history functionality to Talon. It includescommand_history.py
, which manages the command history, andcommand_history.talon
, which defines voice commands to display and manage the history.screenshot
: This directory provides screenshot functionality in Talon. It includesscreenshot.py
which defines the screenshot actions, andscreenshot.talon
which defines voice commands for taking screenshots.mode_indicator
: This directory implements a graphical mode indicator. It includesmode_indicator.py
which defines the logic for displaying the mode indicator, andmode_indicator.talon
which defines the default settings.listening_timeout
: This directory implements a timeout for speech recognition. It containslistening_timeout.py
which implements the timeout logic and settings.
Additionally, the directory contains these files directly in the community/plugin
directory:
paste_to_insert.py
: This file modifies the defaultinsert
action to paste text above a certain threshold defined by theuser.paste_to_insert_threshold
setting. This allows longer blocks of text to be inserted more reliably than by repeatedly pressing keys.README.md
: This file provides a high-level overview of the plugins contained in this directory.eye_tracking_settings.py
: This file contains commented-out code to configure eye tracking and zoom mouse settings.
In summary, the community/plugin
directory serves as a central location for a variety of useful Talon extensions, ranging from simple text manipulation to more complex functionalities like desktop management and custom UI elements. The plugins are implemented as a combination of Python files that handle logic and state, and .talon
files that define the voice commands, often in conjunction with settings files to customize their behavior.