If we can't create the cache dir, e.g. if `~/.cache` doesn't exist or
if we don't have enough permissions, we now return a temporary directory.
Fixes#10033.
- during installation add to the list of custom keyboards if necessary
- during uninstallation remove from the list of custom keyboards
- if list of custom keyboards has invalid values, remove those before
saving the list
Closes#8598.
After this change uninstalling a keyboard will remove all installed
language/keyboard combinations for that particular keyboard.
Previously we only uninstalled for the first language listed in the
keyboard.
This change refactors and cleans uninstall:
- rename methods to make it clear which ones are private/protected
- extract common code
- improve error reporting
- Introduce `InstallKmp` class
- Remove unused `list_files` method
- Extract common method that `install_kmp_shared` and
`install_kmp_user` use
- Make internal methods protected
This improves the implementation for normalizing language tags
when installing a keyboard. Based on the Windows implementation
in `Keyman.System.CanonicalLanguageCodeUtils.pas`.
One difference to the Windows implementation is that the mapping of
3- to 2-letter tags is based on `langtags.json` instead of
`iso639-3.tab`.
Closes#3399.
When installing a keyboard with a bcp47 tag we now look up the
language tag in the keyboard kmp.json file. This fixes#3399 in
case a script subtag is required for the language and will cause
the keyboard to properly show up in the Linux keyboard selection
list.
This change implements the custom keyman:// protocol handler which
will cause the browser to launch km-config when it encounters a
URL using the keyman protocol.
Related to #3271.