diff options
| author | Jules Aguillon | 2026-02-02 00:20:00 +0100 |
|---|---|---|
| committer | GitHub | 2026-02-02 00:20:00 +0100 |
| commit | 77c4a27c4c37b3620defcab94ffd1b2f536c88cb (patch) | |
| tree | 1bf2c5b723e1f86b0904257e7e57f4fda15378e9 /res/values/styles.xml | |
| parent | 2ecf93d9904544ee73159e9f0ee74b49057bca6c (diff) | |
| download | unexpected-keyboard-77c4a27c4c37b3620defcab94ffd1b2f536c88cb.tar.gz unexpected-keyboard-77c4a27c4c37b3620defcab94ffd1b2f536c88cb.zip | |
Spell checking (#1137)
This adds dictionary-based spell checking to the keyboard. The keyboard looks at the word being typed and matches it against a dictionary to either complete the rest of the word or find alternative spellings.
The core of this feature is implemented in cdict, which is included as a
submodule in vendor/cidct.
Cdict is developped at https://github.com/Julow/cdict
The dictionaries are hosted at https://github.com/Julow/Unexpected-Keyboard-dictionaries/
The wordlists used to build the dictionaries are the same ones used by
HeliBoard from https://codeberg.org/Helium314/aosp-dictionaries
- Add an activity accessible from the launcher app that lists available
dictionaries with a download button.
The DictionaryListView view shows the list of available dictionaries and
handles downloading and installing them.
- The Dictionaries class manages installed dictionaries. Dictionaries are
installed as individual files into the app's private directory.
- Available dictionaries are listed in dictionaries.xml, which is generated
when building Unexpected-Keyboard-dictionaries.
method.xml mentions the dictionary name for each locales.
Diffstat (limited to 'res/values/styles.xml')
| -rw-r--r-- | res/values/styles.xml | 33 |
1 files changed, 32 insertions, 1 deletions
diff --git a/res/values/styles.xml b/res/values/styles.xml index 5defb7b..6977e00 100644 --- a/res/values/styles.xml +++ b/res/values/styles.xml @@ -64,7 +64,7 @@ <item name="android:layout_width">fill_parent</item> <item name="android:layout_height">wrap_content</item> <item name="android:layout_marginVertical">8dp</item> - <item name="android:layout_marginHorizontal">16dp</item> + <item name="android:layout_marginHorizontal">24dp</item> <item name="android:layout_gravity">center</item> </style> <style name="anim"> @@ -90,6 +90,37 @@ <item name="android:layout_width">wrap_content</item> <item name="android:orientation">horizontal</item> </style> + <!-- Dictionaries activity --> + <style name="dictionary_list_view"> + <item name="android:layout_width">fill_parent</item> + <item name="android:layout_height">wrap_content</item> + <item name="android:layout_marginVertical">24dp</item> + </style> + <style name="dictionary_download_item"> + <item name="android:orientation">horizontal</item> + <item name="android:layout_width">fill_parent</item> + <item name="android:layout_height">wrap_content</item> + <item name="android:layout_marginVertical">8dp</item> + <item name="android:gravity">center</item> + <item name="android:paddingHorizontal">48dp</item> + </style> + <style name="dictionary_download_locale"> + <item name="android:layout_weight">1</item> + <item name="android:layout_width">fill_parent</item> + <item name="android:layout_height">wrap_content</item> + <item name="android:textSize">16sp</item> + </style> + <style name="dictionary_download_size"> + <item name="android:layout_weight">0</item> + <item name="android:layout_width">wrap_content</item> + <item name="android:layout_height">wrap_content</item> + <item name="android:layout_marginRight">8dp</item> + <item name="android:textSize">12sp</item> + </style> + <style name="dictionary_download_button"> + <item name="android:layout_width">24dp</item> + <item name="android:layout_height">24dp</item> + </style> <style name="appTheme" parent="@android:style/Theme.Material.Light"/> <style name="settingsTheme" parent="appTheme"> <!-- Setting this in the activity theme so it propagate to nested |
