-
Notifications
You must be signed in to change notification settings - Fork 4
WM Keyboard plugins
A plugin is a small Lua script that adds a tool to the keyboard. It draws a panel (some text, a few buttons, maybe a text box) and does whatever you write it to do.
function render()
return ui.column {
ui.label { text = "Hello!", style = "title" },
ui.button { id = "wave", text = "Wave back" },
}
end
function on_event(e)
if e.id == "wave" then wm.log("👋") end
endThat is a complete plugin, minus its plugin.json.
You can also write one on the phone. Tools / Plugins / Write a plugin opens an in-app editor with a live preview and starter templates, and its Install button installs the result directly, with no ZIP file.
- Getting started Build a working cipher tool from an empty folder. Assumes you have never written Lua.
- API reference The manifest, every widget, every event, every wm.* function, and every limit.
- Permissions The one thing a plugin can ask for, and the many it cannot.
- Security What the sandbox does, what it leaves out on purpose, and where the limits really are.
Compute things, and draw its own panel. That is genuinely the whole list.
- See what you type. There is no key event API. A plugin cannot observe, change or delay a single keystroke going to your app.
- Read the text you are writing in. No API returns the contents of the field.
- Read your clipboard. No API.
- Use the internet. No HTTP, no sockets, no URLs.
- Reach Android. No files, no reflection, no other apps, no device information, no permissions of its own.
- Run in the background. A plugin only runs while its panel is open.
These are absences, not settings
No version of a plugin gets around them. The sandbox has no function for any of it. See Security for how that is enforced, and what the residual risks honestly are.
Text still gets into a plugin: you type into its box, or tap Paste on it. Results come back out when you tap Insert under a result. Both directions are a deliberate tap, on a control the keyboard drew.
The five demo plugins in the addon repository are meant to be read:
| Plugin | Shows |
|---|---|
| Cipher Tool | Tabs, inputs, buttons, insertable output. The getting-started build. |
| UI Kitchen Sink | Every widget and every event, with a live event log. |
| Todo List |
wm.storage. The one capability a plugin can ask for. |
| Text Tools | The paste-in, transform, insert-out flow. |
| Math Mode | A real text engine: a tokenizer, symbol tables, a live result on every keystroke, and options kept in wm.storage. |
Enabling plugins
Plugins are off until you ask for them. Turn them on here, with Allow
plugins. Then install one from the Addons screen, or open a .wmplugin file:
Tools / Plugins / Manage plugins
- Home
- Getting started
- Typing
- Languages
- Suggestions & correction
- Emoji & expression
-
Tools
- Clipboard manager
- Voice typing
- Offline voice (Whisper)
- Handwriting
- Scanner (OCR, QR, documents)
- Camera tool
- Translate
- Search, Wikipedia & dictionary
- Media controls
- AI chat
- AI tools
- Utility tools
- Snippets & text expansion
- Text editing & cursor tools
- Instruments
- Trackpad
- Calendar
- App launcher
- Learn from text
- Vocabulary
- Resize the keyboard
- The toolbar
- Themes & appearance
- Addons
- Plugins
- Privacy & security
- Accessibility
-
Reference
- Gesture cheat sheet
- Typing
- Hardware shortcuts
- Deep links & launcher shortcuts
- Key press
- File formats
- Dictionaries & words
- Importing from other keyboards
- Languages
- Importing from Espanso
- Appearance
- Keyboard themes
- Troubleshooting
- Glossary
- Keyboard font
- Easter eggs
- Icons
- Layout & size
- Key layouts
- Rows & bars
- Keyboard modes
- Emoji
- Phone number formats
- Tools
- Addons & plugins
- Reference - Accessibility
- Fingerprint lock
- Reference - Data saver
- Reference - Permissions
- Privacy
- Reference - Selection actions
- Servers
- Reference - Backup & restore
- About & diagnostics
- Statistics
- Settings A–Z
- Development