From a71e58270c4e2e8c88fe997405cbcb48bb864479 Mon Sep 17 00:00:00 2001 From: Albert Y <76888457+filterpaper@users.noreply.github.com> Date: Tue, 14 Mar 2023 03:34:23 +0800 Subject: Document Autocorrect callback functions (#20115) --- docs/feature_autocorrect.md | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'docs') diff --git a/docs/feature_autocorrect.md b/docs/feature_autocorrect.md index aa8d37817d..9f80c93f82 100644 --- a/docs/feature_autocorrect.md +++ b/docs/feature_autocorrect.md @@ -236,6 +236,18 @@ bool apply_autocorrect(uint8_t backspaces, const char *str) { } ``` +### Autocorrect Status + +Additional user callback functions to manipulate Autocorrect: + +| Function | Description | +|----------------------------|----------------------------------------------| +| `autocorrect_enable()` | Turns Autocorrect on. | +| `autocorrect_disable()` | Turns Autocorrect off. | +| `autocorrect_toggle()` | Toggles Autocorrect. | +| `autocorrect_is_enabled()` | Returns true if Autocorrect is currently on. | + + ## Appendix: Trie binary data format :id=appendix This section details how the trie is serialized to byte data in autocorrect_data. You don’t need to care about this to use this autocorrection implementation. But it is documented for the record in case anyone is interested in modifying the implementation, or just curious how it works. -- cgit v1.2.3