Fixes#5700.
Adds support for arm64 (M1) to textinputsource in the Keyman app. All
other executables are already fat with support for both x86_64 and
arm64.
Fixes#5316.
Keyman for macOS did not recognise the updated version number 0x0E00,
which is version 14.0. There are no changes to the file format which
impact Keyman for macOS -- the only change is support for notany and
context for Keyman Engine for Web.
Relates to #5316.
Keyman for mac is still reading from kmp.inf, but was treating it as
UTF-8. However, it is windows-1252 encoding. This was stopping Keyman
from loading the file due to the presence of a (C) symbol.
Keyman for mac *should* be loading kmp.json. This needs to be addressed
as a separate issues.
As the build environment documentation is duplicated across each of the
Keyman platform projects, it has become somewhat convoluted and
inconsistent. This PR moves all the mac-based and shared documentation
into docs/build, with placeholders for Windows and Linux documentation
to be moved in the next PR.
The idea is that a developer can configure their box to build any of the
available projects for that platform (web and android build on all three
main dev platforms).
Keeping the build documentation in one place makes it much simpler to
keep it consistent and up-to-date as well, as well as keeping us aware
of potential dependency conflicts between projects.
The icing on the cake is the resources/devbox/macos/macos.sh script,
which I have tested and takes a bare metal mac box through to a full
Keyman development environment (except XCode, there's always something!)
When working on a new build script, I tripped over the `-?` question
mark help parameter here, as it needs to be escaped. Opted to fix all
the instances in our scripts, although AFAICT there would not have been
current bugs arising from this, as there were no conflicting one
character options lower in the case list.
Fixes#4058.
Fixes#4528.
Prevents duplicate keyboards from appearing in the list. If there are
already duplicates in the list, they will be cleaned up the next time a
keyboard is added or removed in Configuration.
Fixes#3979.
Instead of loading help.keyman.com in the support frame, we now load a
local copy of the help. External links within the help will open in the
user's browser. This avoids issues of navigation to keyboard download
and other sites which won't work well.
Also, adds Back, Forward and Home buttons to the window so the user can
navigate more easily with mouse.
Finally, this means that the local help will always be synchronised with
the app version and brings the macOS help in line with the other
platforms.
Fixes#3972.
Ensure that window controllers are released when we close the window, so
that we are starting again when we want to use the window again in the
future.
There are a number of ugly patterns in this code, but fixing those is
outside scope for the beta.
Fixes#3945.
When the configuration window is opened via `showPreferences`, we were
not aware that the configuration window had been opened, so subsequent
references to it would recreate it.
If multiple copies of a package are saved by a browser, the browser will
typically append a ` (#)` to the filename, where `#` is a number. This
should be stripped off before installation to prevent duplicates of the
package being installed.
Fixes#2488.
Fixes#1953.
Makes it possible to specify additional apps that need 'legacy' handling
without requiring an updated build of Keyman for Mac. The list should be
stored in user defaults under the `KMLegacyApps` key. It can be viewed
with the command:
```
defaults read keyman.inputmethod.Keyman KMLegacyApps
```
And updated with
```
defaults write keyman.inputmethod.Keyman KMLegacyApps -array value1 value2 ...
defaults write keyman.inputmethod.Keyman KMLegacyApps -array-add value1 value2 ...
```
Each entry should be a regex that matches the client app id.
For example:
```
defaults write keyman.inputmethod.Keyman KMLegacyApps -array com.microsoft.Word '^com.github.atom$'
```
(Note for purity, the `.` should be escaped in the regex but it'll
actually be fine without...)
This commit also adds the `keymanDataPath` method on
`KMInputMethodAppDelegate`, so we can place additional configuration
data there in the future (as opposed to in the shared config which is
less easy for users to edit.)
Fixes#3939.
Arrow keys, function keys and a handful of other keys should trigger a
context reload (for legacy apps, that means a context flush). This means
that deadkeys are also flushed when any of these keys are pressed, in
the same way as a Command key or a mouse click already did.
Relates to #3935.
This switches Java apps into legacy mode. However, Java itself will need
patching to support Keyman, as it makes assumptions about input methods,
including matching specific input methods by name, before enabling its
complex text support.
I am in process of submitting a bug report and may try and submit a
patch (although the process seems a little convoluted). It requires a
change to a single file, AWTView.m, with the following diff (against
JDK 16.0):
diff --git a/src/java.desktop/macosx/native/libawt_lwawt/awt/AWTView.m b/src/java.desktop/macosx/native/libawt_lwawt/awt/AWTView.m
index 3e80b5a6cf3..2ae1f4f3f12 100644
--- a/src/java.desktop/macosx/native/libawt_lwawt/awt/AWTView.m
+++ b/src/java.desktop/macosx/native/libawt_lwawt/awt/AWTView.m
@@ -263,6 +263,16 @@ - (void) keyDown: (NSEvent *)event {
fProcessingKeystroke = YES;
fKeyEventsNeeded = YES;
+ if([(NSString *)kbdLayout containsString:@"keyman"]) {
+ // Keyman handles all key events; none should be
+ // passed through as default before Keyman processes them
+ fKeyEventsNeeded = NO;
+ }
// Allow TSM to look at the event and potentially send back NSTextInputClient messages.
[self interpretKeyEvents:[NSArray arrayWithObject:event]];
@@ -960,7 +989,9 @@ - (void) insertText:(id)aString replacementRange:(NSRange)replacementRange
if ((utf16Length > 2) ||
((utf8Length > 1) && [self isCodePointInUnicodeBlockNeedingIMEvent:codePoint]) ||
- ((codePoint == 0x5c) && ([(NSString *)kbdLayout containsString:@"Kotoeri"]))) {
+ ((codePoint == 0x5c) && ([(NSString *)kbdLayout containsString:@"Kotoeri"])) ||
+ ([(NSString *)kbdLayout containsString:@"keyman"])
+ ) {
aStringIsComplex = YES;
}
Fixes#2601.
This PR adds support for the 102nd key as found on European layouts. It
does not however reshape the Enter key and move the BKSLASH key, as that
is a much bigger job; functionally this makes it possible to press the
102nd key, which was the biggest gap.