websites_and_search_engines
The community/core/websites_and_search_engines directory contains files that allow users to quickly navigate to websites and perform searches using voice commands.
-
website.talon-listdefines a list of websites, mapping short names to URLs. For example, "talon home page" maps tohttp://talonvoice.com. This list is used by voice commands to quickly navigate to the listed websites. -
search_engine.talon-listdefines a list of search engines, mapping short names to URLs containing the string%s. This string is later replaced with the user's search query. For example, "google" maps tohttps://www.google.com/search?q=%s. -
websites_and_search_engines.talondefines the Talon voice commands for interacting with the lists defined in the.talon-listfiles. This file contains commands for opening websites by name, opening URLs from selected text or the clipboard, and searching using a specified search engine with a given query or using selected text or the clipboard as a query. For example, "google hunt hello world" would perform a Google search for "hello world". -
websites_and_search_engines.pyis the Python code that implements the actions used by the Talon commands. This file defines thewebsiteandsearch_enginelists as Talon module lists and defines functions such asopen_urlwhich opens a URL in the user's default browser, andsearch_with_search_enginewhich takes a search engine URL from thesearch_enginelist, replaces the%sstring with a URL-encoded version of the user's search query, and opens the resulting URL.