This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import asyncio | |
| import uiautomation as auto | |
| import websockets | |
| PORT = 6677 | |
| def get_caption_text(): | |
| try: | |
| window = auto.WindowControl(searchDepth=1, Name="Live Captions") | |
| text_el = window.TextControl(searchDepth=20, AutomationId="CaptionsTextBlock") |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /** | |
| * Kiku workaround for multiple dictionaries in MainDefinition. | |
| * | |
| * - removes every MainDefinition dictionary from Glossary | |
| * - continues ordered-list numbering across separately rendered | |
| * {single-glossary-*} markers | |
| * | |
| * Put this file in Anki's collection.media folder as _kiku_plugin.js. | |
| * If you already use a Kiku plugin, merge the onPluginLoad body into it. | |
| */ |