chore(developer): Merge branch 'chore/merge-master-into-feature-ldml' into feat/developer/kmldmlc-meta-tests-and-cleanup

This commit is contained in:
Marc Durdin 2022-08-31 10:10:03 +10:00
commit 5d44d2ecc7
31 changed files with 98 additions and 51 deletions

3
.github/labeler.yml vendored
View file

@ -18,7 +18,6 @@ android/samples/: android/Samples/**
common/:
- common/**
- core/**
- resources/**
common/models/: common/models/**
@ -29,7 +28,7 @@ common/models/wordbreakers/: common/models/wordbreakers/**
common/resources/: resources/**
common/web/: common/web/**
common/core/:
core/:
- core/**
developer/:

View file

@ -1,5 +1,30 @@
# Keyman Version History
## 16.0.54 alpha 2022-08-30
* chore(core): rename json.hpp to jsonpp.hpp (#6993)
* chore(developer): remove unused dependencies from KeymanWeb compiler (#7000)
* chore: update core/ label (#7138)
* chore(linux): Update debian changelog (#7145)
* fix(linux): Allow downgrades for installing build deps (#7147)
* chore(core): emcc off path for linux (#7149)
## 16.0.53 alpha 2022-08-29
* feat(linux): Dockerfile for linux builder (#7133)
## 16.0.52 alpha 2022-08-26
* fix(android/engine): Lower the max height for landscape orientation (#7119)
* fix(linux): Remove wrong `ok_for_single_backspace` method (#7123)
## 16.0.51 alpha 2022-08-24
* fix(android): verify browser before starting activity (#7001)
* chore: Change platform advocates per discussion (#7096)
* fix(windows): Add invalidate context action to non-updatable parse (#7089)
* feat(common): add parameter variable support to `builder_` functions (#7103)
## 16.0.50 alpha 2022-08-23
* chore(core): Remove obsolete python keyboardprocessor (#7094)

View file

@ -1 +1 @@
16.0.51
16.0.55

View file

@ -2,7 +2,7 @@
<!-- Dimens for Landscape (Phone) -->
<resources>
<dimen name="banner_height">40dp</dimen>
<dimen name="keyboard_height">150dp</dimen>
<dimen name="keyboard_height">100dp</dimen>
<dimen name="key_width">49.25dp</dimen>
<dimen name="key_height">49.25dp</dimen>
<dimen name="popup_arrow_width">21dp</dimen>

View file

@ -2,7 +2,7 @@
<!-- Dimens for Landscape (Tablet 7") -->
<resources>
<dimen name="banner_height">50dp</dimen>
<dimen name="keyboard_height">200dp</dimen>
<dimen name="keyboard_height">140dp</dimen>
<dimen name="key_width">73.5dp</dimen>
<dimen name="key_height">58.5dp</dimen>
<dimen name="popup_arrow_width">32dp</dimen>

View file

@ -2,7 +2,7 @@
<!-- Dimens for Landscape (Tablet 10") -->
<resources>
<dimen name="banner_height">60dp</dimen>
<dimen name="keyboard_height">300dp</dimen>
<dimen name="keyboard_height">200dp</dimen>
<dimen name="key_width">98.5dp</dimen>
<dimen name="key_height">98.5dp</dimen>
<dimen name="popup_arrow_width">42dp</dimen>

View file

@ -17,7 +17,7 @@ if hotdoc.found()
configuration: cfg)
deps = files(
'../include/keyman/keyboardprocessor.h.in',
'../src/json.hpp',
'../src/jsonpp.hpp',
'../src/utfcodec.hpp'
)

View file

@ -12,7 +12,7 @@
#include <iomanip>
#include <limits>
#include "json.hpp"
#include "jsonpp.hpp"
#if defined(_MSC_VER)

View file

@ -6,7 +6,7 @@
History: 7 Oct 2018 - TSE - Refactored out of km_kbp_keyboard_api.cpp
*/
#include "keyboard.hpp"
#include "json.hpp"
#include "jsonpp.hpp"
using namespace km::kbp;

View file

@ -15,7 +15,7 @@
#include <keyman/keyboardprocessor.h>
#include "context.hpp"
#include "json.hpp"
#include "jsonpp.hpp"
#include "utfcodec.hpp"
namespace {

View file

@ -14,7 +14,7 @@
#include <keyman/keyboardprocessor.h>
#include "processor.hpp"
#include "json.hpp"
#include "jsonpp.hpp"
#include "state.hpp"

View file

@ -13,7 +13,7 @@
#include <sstream>
#include <keyman/keyboardprocessor.h>
#include "json.hpp"
#include "jsonpp.hpp"
#include "processor.hpp"
#include "state.hpp"

View file

@ -68,7 +68,7 @@ lib = library('kmnkbp0',
'km_kbp_state_api.cpp',
'km_kbp_debug_api.cpp',
'km_kbp_processevent_api.cpp',
'json.cpp',
'jsonpp.cpp',
'ldml/ldml_processor.cpp',
'mock/mock_processor.cpp',
'kmx/kmx_consts.cpp',

View file

@ -13,7 +13,7 @@
#include <type_traits>
#include <keyman/keyboardprocessor.h>
#include "json.hpp"
#include "jsonpp.hpp"
#include "utfcodec.hpp"
// Forward declarations

View file

@ -14,7 +14,7 @@
#include <iostream>
#include <fstream>
#include <json.hpp>
#include <jsonpp.hpp>
#ifdef __EMSCRIPTEN__
#include <emscripten.h>

View file

@ -13,7 +13,7 @@ endif
e = executable('jsontest', 'jsontest.cpp',
include_directories: [libsrc],
link_args: links + tests_flags,
objects: lib.extract_objects('json.cpp'))
objects: lib.extract_objects('jsonpp.cpp'))
test('jsontest', e, args: 'jsontest.json')
test('jsontestOutput', python, is_parallel: false, args:
cmpfiles + ['jsontest.json', join_paths(stnds, 'jsontest.json')])

View file

@ -53,7 +53,6 @@ uses
CompileErrorCodes in '..\common\delphi\compiler\CompileErrorCodes.pas',
TouchLayout in '..\tike\oskbuilder\TouchLayout.pas',
TouchLayoutDefinitions in '..\tike\oskbuilder\TouchLayoutDefinitions.pas',
TouchLayoutUtils in '..\tike\oskbuilder\TouchLayoutUtils.pas',
KeyboardFonts in '..\common\delphi\general\KeyboardFonts.pas',
KeyboardParser in '..\tike\main\KeyboardParser.pas',
WindowsLanguages in '..\common\delphi\general\WindowsLanguages.pas',

View file

@ -202,7 +202,6 @@
<DCCReference Include="..\common\delphi\compiler\CompileErrorCodes.pas"/>
<DCCReference Include="..\tike\oskbuilder\TouchLayout.pas"/>
<DCCReference Include="..\tike\oskbuilder\TouchLayoutDefinitions.pas"/>
<DCCReference Include="..\tike\oskbuilder\TouchLayoutUtils.pas"/>
<DCCReference Include="..\common\delphi\general\KeyboardFonts.pas"/>
<DCCReference Include="..\tike\main\KeyboardParser.pas"/>
<DCCReference Include="..\common\delphi\general\WindowsLanguages.pas"/>

View file

@ -73,7 +73,6 @@ uses
OnScreenKeyboardData in '..\..\..\common\windows\delphi\visualkeyboard\OnScreenKeyboardData.pas',
TouchLayout in '..\TIKE\oskbuilder\TouchLayout.pas',
TouchLayoutDefinitions in '..\TIKE\oskbuilder\TouchLayoutDefinitions.pas',
TouchLayoutUtils in '..\TIKE\oskbuilder\TouchLayoutUtils.pas',
KeyboardFonts in '..\common\delphi\general\KeyboardFonts.pas',
Keyman.System.Util.RenderLanguageIcon in '..\..\..\common\windows\delphi\ui\Keyman.System.Util.RenderLanguageIcon.pas',
utilicon in '..\..\..\common\windows\delphi\general\utilicon.pas',

View file

@ -179,7 +179,6 @@
<DCCReference Include="..\..\..\common\windows\delphi\visualkeyboard\OnScreenKeyboardData.pas"/>
<DCCReference Include="..\TIKE\oskbuilder\TouchLayout.pas"/>
<DCCReference Include="..\TIKE\oskbuilder\TouchLayoutDefinitions.pas"/>
<DCCReference Include="..\TIKE\oskbuilder\TouchLayoutUtils.pas"/>
<DCCReference Include="..\common\delphi\general\KeyboardFonts.pas"/>
<DCCReference Include="..\..\..\common\windows\delphi\ui\Keyman.System.Util.RenderLanguageIcon.pas"/>
<DCCReference Include="..\..\..\common\windows\delphi\general\utilicon.pas"/>

View file

@ -72,14 +72,8 @@ uses
WindowsLanguages in '..\..\..\common\delphi\general\WindowsLanguages.pas',
KeymanWebKeyCodes in '..\..\..\tike\compile\KeymanWebKeyCodes.pas',
kmxfileutils in '..\..\..\..\..\common\windows\delphi\keyboards\kmxfileutils.pas',
TikeUnicodeData in '..\..\..\tike\main\TikeUnicodeData.pas',
UnicodeData in '..\..\..\..\..\common\windows\delphi\charmap\UnicodeData.pas',
ADODB_TLB in '..\..\..\..\..\common\windows\delphi\tlb\ADODB_TLB.pas',
ADOX_TLB in '..\..\..\..\..\common\windows\delphi\tlb\ADOX_TLB.pas',
ttinfo in '..\..\..\..\..\common\windows\delphi\general\ttinfo.pas',
TouchLayoutDefinitions in '..\..\..\tike\oskbuilder\TouchLayoutDefinitions.pas',
TouchLayout in '..\..\..\tike\oskbuilder\TouchLayout.pas',
TouchLayoutUtils in '..\..\..\tike\oskbuilder\TouchLayoutUtils.pas',
KeyboardFonts in '..\..\..\common\delphi\general\KeyboardFonts.pas',
Keyman.Developer.System.Project.kpsProjectFile in '..\..\..\tike\project\Keyman.Developer.System.Project.kpsProjectFile.pas',
Keyman.Developer.System.Project.kpsProjectFileAction in '..\..\..\tike\project\Keyman.Developer.System.Project.kpsProjectFileAction.pas',

View file

@ -153,14 +153,8 @@
<DCCReference Include="..\..\..\common\delphi\general\WindowsLanguages.pas"/>
<DCCReference Include="..\..\..\tike\compile\KeymanWebKeyCodes.pas"/>
<DCCReference Include="..\..\..\..\..\common\windows\delphi\keyboards\kmxfileutils.pas"/>
<DCCReference Include="..\..\..\tike\main\TikeUnicodeData.pas"/>
<DCCReference Include="..\..\..\..\..\common\windows\delphi\charmap\UnicodeData.pas"/>
<DCCReference Include="..\..\..\..\..\common\windows\delphi\tlb\ADODB_TLB.pas"/>
<DCCReference Include="..\..\..\..\..\common\windows\delphi\tlb\ADOX_TLB.pas"/>
<DCCReference Include="..\..\..\..\..\common\windows\delphi\general\ttinfo.pas"/>
<DCCReference Include="..\..\..\tike\oskbuilder\TouchLayoutDefinitions.pas"/>
<DCCReference Include="..\..\..\tike\oskbuilder\TouchLayout.pas"/>
<DCCReference Include="..\..\..\tike\oskbuilder\TouchLayoutUtils.pas"/>
<DCCReference Include="..\..\..\common\delphi\general\KeyboardFonts.pas"/>
<DCCReference Include="..\..\..\tike\project\Keyman.Developer.System.Project.kpsProjectFile.pas"/>
<DCCReference Include="..\..\..\tike\project\Keyman.Developer.System.Project.kpsProjectFileAction.pas"/>

View file

@ -36,6 +36,8 @@ implementation
uses
System.SysUtils,
Winapi.ActiveX,
compile,
CompilePackage,
Keyman.Developer.System.Project.kmnProjectFileAction,
@ -154,5 +156,8 @@ begin
end;
initialization
CoInitializeEx(nil, COINIT_APARTMENTTHREADED);
TDUnitX.RegisterTestFixture(TCompilePackageVersioningTest);
finalization
CoUninitialize;
end.

View file

@ -273,14 +273,11 @@ uses
CompileErrorCodes,
JsonUtil,
KeymanDeveloperOptions,
KeyboardParser,
Keyman.System.KeyboardUtils,
KeymanWebKeyCodes,
kmxfileutils,
TouchLayout,
TouchLayoutUtils,
Unicode,
UnicodeData,
utilstr,
VisualKeyboard,
VKeys;

View file

@ -64,3 +64,23 @@ All dependencies are already installed if you followed the instructions under [P
Building:
* [Building Keyman Core](../../core/doc/BUILDING.md)
## Docker Builder
The Docker builder allows you to perform a linux build from anywhere Docker is supported.
To build the docker image:
```shell
cd ../../linux
docker pull ubuntu:latest
docker build . -t keymanapp/keyman-linux-builder:latest
```
Once the image is built, it may be used to build parts of Keyman.
```shell
cd ../core
# keep linux build artifacts separate
mkdir -p build/linux
docker run -it --rm -v $(pwd)/..:/home/build -v $(pwd)/build/linux:/home/build/core/build keyman-linux-builder:latest bash -c 'cd core; bash build.sh -d'
```

24
linux/Dockerfile Normal file
View file

@ -0,0 +1,24 @@
# Copyright (c) 2022 SIL International. All rights reserved.
#
# builder image for a linux build
# see ../docs/build/linux-ubuntu.md
FROM --platform=amd64 ubuntu:latest
LABEL org.opencontainers.image.authors="SIL International."
LABEL org.opencontainers.image.url="https://github.com/keymanapp/keyman.git"
LABEL org.opencontainers.image.title="Keyman Linux Build Image"
# We will switch to a build user after some installation
USER root
RUN useradd -c "Build user" -d $HOME -m build
ENV HOME /home/build
VOLUME /home/build
WORKDIR /home/build
ENV DEBIAN_FRONTEND noninteractive
# Update to the latest
RUN apt-get -q -y update && apt-get -q -y upgrade
RUN apt-get -q -y install devscripts equivs meson python3 python3-setuptools
ADD debian/control /tmp/control
# Answer 'yes' to install questions
RUN (yes | mk-build-deps --install /tmp/control) || true
# now, switch to build user
USER build

View file

@ -1,3 +1,10 @@
keyman (15.0.269-1) unstable; urgency=medium
* New upstream release.
* Re-release to Debian
-- Eberhard Beilharz <eb1@sil.org> Mon, 29 Aug 2022 15:14:16 +0200
keyman (15.0.268-1) unstable; urgency=medium
* New upstream release.

View file

@ -508,16 +508,6 @@ static void forward_backspace(IBusKeymanEngine *keyman, unsigned int state)
ibus_engine_forward_key_event((IBusEngine *)keyman, KEYMAN_BACKSPACE_KEYSYM, KEYMAN_BACKSPACE, state);
}
static gboolean ok_for_single_backspace(const km_kbp_action_item *action_items, int i, size_t num_actions)
{
for (int j=i+1; j < num_actions; j++) {
if (action_items[i].type == KM_KBP_IT_BACK || action_items[i].type == KM_KBP_IT_CHAR || action_items[i].type == KM_KBP_IT_EMIT_KEYSTROKE) {
return FALSE;
}
}
return TRUE;
}
static gboolean
process_unicode_char_action(
IBusKeymanEngine *keyman,
@ -601,10 +591,6 @@ process_backspace_action(
}
g_free(keyman->char_buffer);
keyman->char_buffer = new_buffer;
} else if (ok_for_single_backspace(action_items, i, num_action_items)) {
// single backspace can be handled by ibus as normal
g_message("no char actions, just single back");
return FALSE;
} else {
g_message(
"DAR: process_backspace_action - client_capabilities=%x, %x", engine->client_capabilities, IBUS_CAP_SURROUNDING_TEXT);

View file

@ -54,7 +54,7 @@ ibus_keyman_tests_SOURCES = \
testfixture.cpp \
testmodule.c \
testmodule.h \
../../../core/src/json.cpp \
../../../core/src/jsonpp.cpp \
../../../core/src/keyboard.cpp \
../../../core/src/kmx/kmx_actions.cpp \
../../../core/src/kmx/kmx_actions.h \

View file

@ -55,7 +55,7 @@ checkAndInstallRequirements()
fi
sudo mk-build-deps debian/control
sudo apt-get -qy install ./keyman-build-deps_*.deb
sudo apt-get -qy --allow-downgrades install ./keyman-build-deps_*.deb
sudo rm -f keyman-buid-deps_*
}