Fixes#2690.
Fixes#3082.
In the debugger, key events such as Enter, Ctrl+C, Ctrl+V were being
swallowed by the debug engine if they did not have rules within the
keyboard. This change emits the key events so the debug memo can
process them normally.
Fixes#1692.
The wrong option was being set -- not sure how this was missed earlier!
Also ensures that TSV files will always use Tabs, regardless of the
global setting.
Fixes#3000.
The model editor would save .model.ts files with Windows-1252 (aka ANSI)
encoding, losing non-ANSI characters in the process.
While fixing this, noted that the class member `model` was not being
used apart from in Load (no longer in Save), so reduced its
scope accordingly.
Fixes#4110.
CEF will create a debug.log file in the current folder if it encounters
an error. Instead, it should be written to Keyman's diag folder. This
fix is for both Keyman Developer and Keyman for Windows.
Fixes#4184.
If a package had a keyboard with language metadata, it would not
load that language data correctly, which then meant it would not
apply the mitigation correctly either, leading to a double elevation
dialog as Keyman tried to fallback to primary language.
Relates to #4116. This may not yet fix the issue; I don't have enough detail
to be sure of what the precise problem is. I have added one change to add a
username to the task definition, which may make a difference; and I will be
monitoring the more fine-grained exception reporting if that doesn't fix the
problem.
Fixes#1285.
If running Windows 10 19597 or later, the underlying issue has
been addressed, so disable the mitigation for new installs of
the keyboard. Does not attempt to change the language code if
the keyboard is already installed.
The keyboard profile and registration strategy was not taking into
account the mitigation for Win10 1803 (#1285) and this meant that the
Amharic, Tigrigna and Sinhala keyboards would not install correctly.
Fixes#4013.
This turned out to be a lot more complicated than I expected, mostly due
to limitations in the Windows Shell API with regard to multiple monitors
and per-monitor DPI awareness (which we don't yet do in Keyman -- a
task for another day). Some of the Shell API functions are also
re-entrant, which is dangerous, so I avoided using those.
We now popup the menu relative to the Keyman icon far more precisely
which gives a much nicer feel to the menu interaction.
This change has three fixes to improve the reliability of notifying
Keyman Engine of updates to settings or keyboard installs:
1. It removes the closure pattern of the refresh thread, because that
was closing on a variable on a different thread (`RefreshHandle`) and
that could cause races and/or exceptions in the case of early free.
What's more, the closure was actually unnecessary as the variable was
really only used by the refresh thread!
2. It moves responsibility for setting the refresh token to the calling
thread so that the caller can depend on the token being the one that
is actually sent, removing a race.
3. Most important, the refresh thread now flushes all messages in its
queue, as there may be multiple messages relating to the window
construction that need to be processed before the wm_keyman_refresh
message can be handled. This greatly improves the chance of the
notification actually being sent!
Fixes#4041.
Show the version with tier and build flags in Setup so that it is clear
which version of Keyman will be installed, as the Keyman version can be
distinct from the setup.exe version.
Constructs the version tag from version+stability data in the
UpdateCheckResponse and uses a new MSI property called VersionWithTag
for Windows Installers. Older MSIs will still show a.b.c.d versions
instead of the tagged version if they are checked locally (as opposed to
online), because the new VersionWithTag property will not be present.
Another thought: we could also try refreshing every 125msec for 5
seconds after the first change is detected. It's a bit yuck perf-wise
but would probably be pretty transparent to the user.
In testing, this looks good. It means the changes appear as soon as
ready, without substantial delays or performance issues. Polling this
makes me feel a bit dirty, but I'll just take a shower and be okay.
As Keyman now monitors the Windows keyboard list from Control Panel, it
is no longer sufficient to refresh the toolbar only when a Keyman
keyboard is updated, as at that point Windows has not refreshed its own
language list in the registry. Instead, we need to monitor changes to
the relevant registry key and then refresh when those changes are
'complete'.
There is a problem: there does not appear to be a good way to monitor
for changes to Windows language settings. WM_SETTINGCHANGE is sent when
a language is added by the user in Settings, but the actual change
happens asynchronously, and we are not notified when the changes are
complete.
We also do not get notifications when languages are added via APIs.
Given the async nature of the language profile changes, this leads to
race conditions when we try to refresh the OSK toolbar. My preferred
solution currently is to monitor the relevant key in a separate thread,
and wait 1 second post-changes to actually do the refresh.
Fixes#4006.
This fixes the list error exception which was masking the actual cause
of #4006, which is already fixed by #4164.
Related issue #4119 is also fixed by #4164.